Home > Archive > microsoft.public.sqlserver.server > August 2002 > sp_attach_db with more than 16 files





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author sp_attach_db with more than 16 files
Kevin

2002-08-02, 12:25 pm

Is there a way to attach a database in SQL Server 2000 with more than 16
files?
I have a large database with 12 groups and some of the groups have more than
16 files.

I rather not using restore but using detach/attach for moving database from
1 server to another.

Thanks!


Andrew J. Kelly

2002-08-02, 12:25 pm

Take a look at CREATE DATABASE with the WITH ATTACH option.

--
Andrew J. Kelly SQL MVP
Targitinteractive, Inc.



"Kevin" <Kevin@nomail.com> wrote in message
news:#K6bJokOCHA.1632@tkmsftngp13...
> Is there a way to attach a database in SQL Server 2000 with more than 16
> files?
> I have a large database with 12 groups and some of the groups have more

than
> 16 files.
>
> I rather not using restore but using detach/attach for moving database

from
> 1 server to another.
>
> Thanks!
>
>



Sue Hoegemeier

2002-08-02, 12:25 pm

You need to use create database with the for attach clause
if you have more than 16 files.

-Sue

On Fri, 2 Aug 2002 10:30:25 -0700, "Kevin"
<Kevin@nomail.com> wrote:

>Is there a way to attach a database in SQL Server 2000 with more than 16
>files?
>I have a large database with 12 groups and some of the groups have more than
>16 files.
>
>I rather not using restore but using detach/attach for moving database from
>1 server to another.
>
>Thanks!
>


Robert Zeurunkl

2002-08-02, 2:25 pm

It's funny, but I was just reading an Access-VB_SqlServer Advisor article
about this just yesterday!

The author was talking about using sp_attach_db and sp_detach_db, and
mentioned the 16 file limit. Then asked "But who has more than 16 files,
anyway?"

heh.

Anyway, I'd recommend making a COPY of db_attach_db stored procedure (name
it kev_attach_db or something) then modify it and add support for additional
parameters. sp_attach_db is limited to 16 files only because it has just 16
input filename parameters. It's a real simple sp, and adding additional
parameters to handle your additional files ought to be a snap.

Kirby
kirby (at) wallaceinfo (dot) com


"Kevin" <Kevin@nomail.com> wrote in message
news:#K6bJokOCHA.1632@tkmsftngp13...
> Is there a way to attach a database in SQL Server 2000 with more than 16
> files?
> I have a large database with 12 groups and some of the groups have more

than
> 16 files.
>
> I rather not using restore but using detach/attach for moving database

from
> 1 server to another.
>
> Thanks!
>
>



Sponsored Links





Free Braindumps | MCSE braindumps software forum

Copyright 2003 - 2008 examnotes.net