Showing posts with label remote. Show all posts
Showing posts with label remote. Show all posts

Wednesday, March 21, 2012

Move the contents of a table from local server to remote server(main server)

hi, I am having a problem in exporting or importind data into a table from
one server to another .Actually some time the connection breaks or the
server gives error message as primary pane full.and the process is
termineted.Can u please suggest me some method to transfer the table and its
content from one table to another in lesser time and with more accuracy.
Thanks and regard,
Irshad Ahmad.Hello Irshad,
Which method are you using to Tranfer the Data ?
Is it between SQL Servers ?
Could you post the exact error message reported by the tool ?
Thanks & Regards
Vishal|||yah i am transferring the data between sqlservers and the error generated is
"Primary File group Full" after something around 30 -40 thousand rows have
been transferred.
"Vishal Gandhi" <vishalg@.microsoft.com> wrote in message
news:KSsMFAxgGHA.4896@.TK2MSFTNGXA01.phx.gbl...
> Hello Irshad,
> Which method are you using to Tranfer the Data ?
> Is it between SQL Servers ?
> Could you post the exact error message reported by the tool ?
> Thanks & Regards
> Vishal
>|||Increase the size of the database file which is full (probably the mdf file).
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Irshad Ahmad" <efextra@.newsgroups.nospam> wrote in message
news:efNZGR9gGHA.896@.TK2MSFTNGP02.phx.gbl...
> yah i am transferring the data between sqlservers and the error generated is "Primary File group
> Full" after something around 30 -40 thousand rows have been transferred.
> "Vishal Gandhi" <vishalg@.microsoft.com> wrote in message
> news:KSsMFAxgGHA.4896@.TK2MSFTNGXA01.phx.gbl...
>> Hello Irshad,
>> Which method are you using to Tranfer the Data ?
>> Is it between SQL Servers ?
>> Could you post the exact error message reported by the tool ?
>> Thanks & Regards
>> Vishal
>

Move the contents of a table from local server to remote server(main server)

hi, I am having a problem in exporting or importind data into a table from
one server to another .Actually some time the connection breaks or the
server gives error message as primary pane full.and the process is
termineted.Can u please suggest me some method to transfer the table and its
content from one table to another in lesser time and with more accuracy.
Thanks and regard,
Irshad Ahmad.Hello Irshad,
Which method are you using to Tranfer the Data ?
Is it between SQL Servers ?
Could you post the exact error message reported by the tool ?
Thanks & Regards
Vishal|||yah i am transferring the data between sqlservers and the error generated is
"Primary File group Full" after something around 30 -40 thousand rows have
been transferred.
"Vishal Gandhi" <vishalg@.microsoft.com> wrote in message
news:KSsMFAxgGHA.4896@.TK2MSFTNGXA01.phx.gbl...
> Hello Irshad,
> Which method are you using to Tranfer the Data ?
> Is it between SQL Servers ?
> Could you post the exact error message reported by the tool ?
> Thanks & Regards
> Vishal
>|||Increase the size of the database file which is full (probably the mdf file)
.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Irshad Ahmad" <efextra@.newsgroups.nospam> wrote in message
news:efNZGR9gGHA.896@.TK2MSFTNGP02.phx.gbl...
> yah i am transferring the data between sqlservers and the error generated
is "Primary File group
> Full" after something around 30 -40 thousand rows have been transferred.
> "Vishal Gandhi" <vishalg@.microsoft.com> wrote in message
> news:KSsMFAxgGHA.4896@.TK2MSFTNGXA01.phx.gbl...
>

Monday, March 12, 2012

move sql 2000 db to sql 2005

Hi, All,
I want to move sql 2000 db to sql 2005, including data and user. The sql
2005 is on the remote server rather than local one. I knew using
import/export to move data, but don't know on how to move user info. Also
using copy database can copy 2000 to 2005, but before copy, need no
application and service to access 2000 db, so 1) how to make no application
and service access database? 2) anyone can tell detail procedure on how to
move?
Thanks in advance for your time,
Martin
Thank you.
as for sp_help_revlogin procedure from KB, what is KB?
"Tibor Karaszi" wrote:

> I suggest you use BACKUP and RESTORE to move the database. It is fully online. Also, get the
> sp_help_revlogin procedure from KB and use that to move over your login (this way the users' SID
> will match the login's SID).
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
>
> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> news:E297ABCE-4F35-46CC-8BAC-98F803BA17B9@.microsoft.com...
>
|||Thanks again
"Tibor Karaszi" wrote:

> KB = Microsoft KnowledgeBase:
> http://support.microsoft.com/default.aspx?scid=fh;EN-US;kbhowto&sd=GN&=EN-US&FR=0
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
>
> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> news:4CDECE99-FCEC-45AA-9090-B5CA8385C70C@.microsoft.com...
>
|||Hi, All,
Import/Export, Copy Database Wizard, and Backup/Restore can copy sql 2000
data to sql 2005, can anyone know which is better way to upgrade sql 2000 to
2005?
Thanks,
Martin
"Tibor Karaszi" wrote:

> KB = Microsoft KnowledgeBase:
> http://support.microsoft.com/default.aspx?scid=fh;EN-US;kbhowto&sd=GN&=EN-US&FR=0
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
>
> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> news:4CDECE99-FCEC-45AA-9090-B5CA8385C70C@.microsoft.com...
>
|||Thank you all for this help!
Martin
"Tibor Karaszi" wrote:

> I believe that there has been some bugs in Copy Database Wizard. I've only read about them, didn't
> memorize them, but it was enough for me to avoid it. I'm sure MS has been working on for sp2,
> though.
> I generally prefer working on the binary level (backup/restore or detach/attach) instead of
> Export/Import. When you use the later, the database is scripted (a bunch of CREATE statements), the
> script files are executed against the destination, and then the data is transferred. If you aren't
> prepared to handle any possible errors in the script handling (if it isn't "your" data model"), then
> I recommend against Export/Import.
> That leaves us with detach/attach (which is what Copy Database Wizard is using) and BACKUP/RESTORE.
> I prefer Backup/Restore as that don't affect the source database, and the amount of data to transfer
> is less (empty space isn't included in backup), I only get one file etc.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
>
> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> news:F6C87F0D-2BBD-40F8-90C4-9F9A40CFE0D4@.microsoft.com...
>
|||The best thing would be detach and create for attach. I did the same for a
1.5TB database having 4 datafiles on multiple filegroups. It all went well
on SQL2005.
Note: You might have to run dbcc checkdb, dbcc updateusage after the
mgiration.
thks,
Manikanth.S
MCDBA.
"martin1" <martin1@.discussions.microsoft.com> wrote in message
news:37F7AE5F-69C0-4C67-9CF7-23320A3911F1@.microsoft.com...[vbcol=seagreen]
> Thank you all for this help!
> Martin
> "Tibor Karaszi" wrote:

move sql 2000 db to sql 2005

Hi, All,
I want to move sql 2000 db to sql 2005, including data and user. The sql
2005 is on the remote server rather than local one. I knew using
import/export to move data, but don't know on how to move user info. Also
using copy database can copy 2000 to 2005, but before copy, need no
application and service to access 2000 db, so 1) how to make no application
and service access database? 2) anyone can tell detail procedure on how to
move?
Thanks in advance for your time,
MartinI suggest you use BACKUP and RESTORE to move the database. It is fully online. Also, get the
sp_help_revlogin procedure from KB and use that to move over your login (this way the users' SID
will match the login's SID).
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"martin1" <martin1@.discussions.microsoft.com> wrote in message
news:E297ABCE-4F35-46CC-8BAC-98F803BA17B9@.microsoft.com...
> Hi, All,
> I want to move sql 2000 db to sql 2005, including data and user. The sql
> 2005 is on the remote server rather than local one. I knew using
> import/export to move data, but don't know on how to move user info. Also
> using copy database can copy 2000 to 2005, but before copy, need no
> application and service to access 2000 db, so 1) how to make no application
> and service access database? 2) anyone can tell detail procedure on how to
> move?
> Thanks in advance for your time,
> Martin|||Thank you.
as for sp_help_revlogin procedure from KB, what is KB?
"Tibor Karaszi" wrote:
> I suggest you use BACKUP and RESTORE to move the database. It is fully online. Also, get the
> sp_help_revlogin procedure from KB and use that to move over your login (this way the users' SID
> will match the login's SID).
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
>
> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> news:E297ABCE-4F35-46CC-8BAC-98F803BA17B9@.microsoft.com...
> > Hi, All,
> >
> > I want to move sql 2000 db to sql 2005, including data and user. The sql
> > 2005 is on the remote server rather than local one. I knew using
> > import/export to move data, but don't know on how to move user info. Also
> > using copy database can copy 2000 to 2005, but before copy, need no
> > application and service to access 2000 db, so 1) how to make no application
> > and service access database? 2) anyone can tell detail procedure on how to
> > move?
> >
> > Thanks in advance for your time,
> > Martin
>|||KB = Microsoft KnowledgeBase:
http://support.microsoft.com/default.aspx?scid=fh;EN-US;kbhowto&sd=GN&=EN-US&FR=0
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"martin1" <martin1@.discussions.microsoft.com> wrote in message
news:4CDECE99-FCEC-45AA-9090-B5CA8385C70C@.microsoft.com...
> Thank you.
> as for sp_help_revlogin procedure from KB, what is KB?
> "Tibor Karaszi" wrote:
>> I suggest you use BACKUP and RESTORE to move the database. It is fully online. Also, get the
>> sp_help_revlogin procedure from KB and use that to move over your login (this way the users' SID
>> will match the login's SID).
>> --
>> Tibor Karaszi, SQL Server MVP
>> http://www.karaszi.com/sqlserver/default.asp
>> http://www.solidqualitylearning.com/
>>
>> "martin1" <martin1@.discussions.microsoft.com> wrote in message
>> news:E297ABCE-4F35-46CC-8BAC-98F803BA17B9@.microsoft.com...
>> > Hi, All,
>> >
>> > I want to move sql 2000 db to sql 2005, including data and user. The sql
>> > 2005 is on the remote server rather than local one. I knew using
>> > import/export to move data, but don't know on how to move user info. Also
>> > using copy database can copy 2000 to 2005, but before copy, need no
>> > application and service to access 2000 db, so 1) how to make no application
>> > and service access database? 2) anyone can tell detail procedure on how to
>> > move?
>> >
>> > Thanks in advance for your time,
>> > Martin
>>|||Thanks again
"Tibor Karaszi" wrote:
> KB = Microsoft KnowledgeBase:
> http://support.microsoft.com/default.aspx?scid=fh;EN-US;kbhowto&sd=GN&=EN-US&FR=0
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
>
> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> news:4CDECE99-FCEC-45AA-9090-B5CA8385C70C@.microsoft.com...
> > Thank you.
> >
> > as for sp_help_revlogin procedure from KB, what is KB?
> >
> > "Tibor Karaszi" wrote:
> >
> >> I suggest you use BACKUP and RESTORE to move the database. It is fully online. Also, get the
> >> sp_help_revlogin procedure from KB and use that to move over your login (this way the users' SID
> >> will match the login's SID).
> >>
> >> --
> >> Tibor Karaszi, SQL Server MVP
> >> http://www.karaszi.com/sqlserver/default.asp
> >> http://www.solidqualitylearning.com/
> >>
> >>
> >> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> >> news:E297ABCE-4F35-46CC-8BAC-98F803BA17B9@.microsoft.com...
> >> > Hi, All,
> >> >
> >> > I want to move sql 2000 db to sql 2005, including data and user. The sql
> >> > 2005 is on the remote server rather than local one. I knew using
> >> > import/export to move data, but don't know on how to move user info. Also
> >> > using copy database can copy 2000 to 2005, but before copy, need no
> >> > application and service to access 2000 db, so 1) how to make no application
> >> > and service access database? 2) anyone can tell detail procedure on how to
> >> > move?
> >> >
> >> > Thanks in advance for your time,
> >> > Martin
> >>
> >>
>|||Hi, All,
Import/Export, Copy Database Wizard, and Backup/Restore can copy sql 2000
data to sql 2005, can anyone know which is better way to upgrade sql 2000 to
2005?
Thanks,
Martin
"Tibor Karaszi" wrote:
> KB = Microsoft KnowledgeBase:
> http://support.microsoft.com/default.aspx?scid=fh;EN-US;kbhowto&sd=GN&=EN-US&FR=0
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
>
> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> news:4CDECE99-FCEC-45AA-9090-B5CA8385C70C@.microsoft.com...
> > Thank you.
> >
> > as for sp_help_revlogin procedure from KB, what is KB?
> >
> > "Tibor Karaszi" wrote:
> >
> >> I suggest you use BACKUP and RESTORE to move the database. It is fully online. Also, get the
> >> sp_help_revlogin procedure from KB and use that to move over your login (this way the users' SID
> >> will match the login's SID).
> >>
> >> --
> >> Tibor Karaszi, SQL Server MVP
> >> http://www.karaszi.com/sqlserver/default.asp
> >> http://www.solidqualitylearning.com/
> >>
> >>
> >> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> >> news:E297ABCE-4F35-46CC-8BAC-98F803BA17B9@.microsoft.com...
> >> > Hi, All,
> >> >
> >> > I want to move sql 2000 db to sql 2005, including data and user. The sql
> >> > 2005 is on the remote server rather than local one. I knew using
> >> > import/export to move data, but don't know on how to move user info. Also
> >> > using copy database can copy 2000 to 2005, but before copy, need no
> >> > application and service to access 2000 db, so 1) how to make no application
> >> > and service access database? 2) anyone can tell detail procedure on how to
> >> > move?
> >> >
> >> > Thanks in advance for your time,
> >> > Martin
> >>
> >>
>|||I believe that there has been some bugs in Copy Database Wizard. I've only read about them, didn't
memorize them, but it was enough for me to avoid it. I'm sure MS has been working on for sp2,
though.
I generally prefer working on the binary level (backup/restore or detach/attach) instead of
Export/Import. When you use the later, the database is scripted (a bunch of CREATE statements), the
script files are executed against the destination, and then the data is transferred. If you aren't
prepared to handle any possible errors in the script handling (if it isn't "your" data model"), then
I recommend against Export/Import.
That leaves us with detach/attach (which is what Copy Database Wizard is using) and BACKUP/RESTORE.
I prefer Backup/Restore as that don't affect the source database, and the amount of data to transfer
is less (empty space isn't included in backup), I only get one file etc.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"martin1" <martin1@.discussions.microsoft.com> wrote in message
news:F6C87F0D-2BBD-40F8-90C4-9F9A40CFE0D4@.microsoft.com...
> Hi, All,
> Import/Export, Copy Database Wizard, and Backup/Restore can copy sql 2000
> data to sql 2005, can anyone know which is better way to upgrade sql 2000 to
> 2005?
> Thanks,
> Martin
> "Tibor Karaszi" wrote:
>> KB = Microsoft KnowledgeBase:
>> http://support.microsoft.com/default.aspx?scid=fh;EN-US;kbhowto&sd=GN&=EN-US&FR=0
>> --
>> Tibor Karaszi, SQL Server MVP
>> http://www.karaszi.com/sqlserver/default.asp
>> http://www.solidqualitylearning.com/
>>
>> "martin1" <martin1@.discussions.microsoft.com> wrote in message
>> news:4CDECE99-FCEC-45AA-9090-B5CA8385C70C@.microsoft.com...
>> > Thank you.
>> >
>> > as for sp_help_revlogin procedure from KB, what is KB?
>> >
>> > "Tibor Karaszi" wrote:
>> >
>> >> I suggest you use BACKUP and RESTORE to move the database. It is fully online. Also, get the
>> >> sp_help_revlogin procedure from KB and use that to move over your login (this way the users'
>> >> SID
>> >> will match the login's SID).
>> >>
>> >> --
>> >> Tibor Karaszi, SQL Server MVP
>> >> http://www.karaszi.com/sqlserver/default.asp
>> >> http://www.solidqualitylearning.com/
>> >>
>> >>
>> >> "martin1" <martin1@.discussions.microsoft.com> wrote in message
>> >> news:E297ABCE-4F35-46CC-8BAC-98F803BA17B9@.microsoft.com...
>> >> > Hi, All,
>> >> >
>> >> > I want to move sql 2000 db to sql 2005, including data and user. The sql
>> >> > 2005 is on the remote server rather than local one. I knew using
>> >> > import/export to move data, but don't know on how to move user info. Also
>> >> > using copy database can copy 2000 to 2005, but before copy, need no
>> >> > application and service to access 2000 db, so 1) how to make no application
>> >> > and service access database? 2) anyone can tell detail procedure on how to
>> >> > move?
>> >> >
>> >> > Thanks in advance for your time,
>> >> > Martin
>> >>
>> >>
>>|||Backup / restore is best, as it copies everything and gives you the ability
to save the intermediate state. The Copy Database Wizard is the easiest to
use, it also copies everything. Import/Export discards a lot of imformation
and is therefore not an option for copying whole databases.
If you are replacing SQL2000 with SQL2005, you can also just detach and
attach the files.
"martin1" <martin1@.discussions.microsoft.com> wrote in message
news:F6C87F0D-2BBD-40F8-90C4-9F9A40CFE0D4@.microsoft.com...
> Hi, All,
> Import/Export, Copy Database Wizard, and Backup/Restore can copy sql 2000
> data to sql 2005, can anyone know which is better way to upgrade sql 2000
> to
> 2005?
> Thanks,
> Martin
> "Tibor Karaszi" wrote:
>> KB = Microsoft KnowledgeBase:
>> http://support.microsoft.com/default.aspx?scid=fh;EN-US;kbhowto&sd=GN&=EN-US&FR=0
>> --
>> Tibor Karaszi, SQL Server MVP
>> http://www.karaszi.com/sqlserver/default.asp
>> http://www.solidqualitylearning.com/
>>
>> "martin1" <martin1@.discussions.microsoft.com> wrote in message
>> news:4CDECE99-FCEC-45AA-9090-B5CA8385C70C@.microsoft.com...
>> > Thank you.
>> >
>> > as for sp_help_revlogin procedure from KB, what is KB?
>> >
>> > "Tibor Karaszi" wrote:
>> >
>> >> I suggest you use BACKUP and RESTORE to move the database. It is fully
>> >> online. Also, get the
>> >> sp_help_revlogin procedure from KB and use that to move over your
>> >> login (this way the users' SID
>> >> will match the login's SID).
>> >>
>> >> --
>> >> Tibor Karaszi, SQL Server MVP
>> >> http://www.karaszi.com/sqlserver/default.asp
>> >> http://www.solidqualitylearning.com/
>> >>
>> >>
>> >> "martin1" <martin1@.discussions.microsoft.com> wrote in message
>> >> news:E297ABCE-4F35-46CC-8BAC-98F803BA17B9@.microsoft.com...
>> >> > Hi, All,
>> >> >
>> >> > I want to move sql 2000 db to sql 2005, including data and user. The
>> >> > sql
>> >> > 2005 is on the remote server rather than local one. I knew using
>> >> > import/export to move data, but don't know on how to move user info.
>> >> > Also
>> >> > using copy database can copy 2000 to 2005, but before copy, need no
>> >> > application and service to access 2000 db, so 1) how to make no
>> >> > application
>> >> > and service access database? 2) anyone can tell detail procedure on
>> >> > how to
>> >> > move?
>> >> >
>> >> > Thanks in advance for your time,
>> >> > Martin
>> >>
>> >>
>>|||Thank you all for this help!
Martin
"Tibor Karaszi" wrote:
> I believe that there has been some bugs in Copy Database Wizard. I've only read about them, didn't
> memorize them, but it was enough for me to avoid it. I'm sure MS has been working on for sp2,
> though.
> I generally prefer working on the binary level (backup/restore or detach/attach) instead of
> Export/Import. When you use the later, the database is scripted (a bunch of CREATE statements), the
> script files are executed against the destination, and then the data is transferred. If you aren't
> prepared to handle any possible errors in the script handling (if it isn't "your" data model"), then
> I recommend against Export/Import.
> That leaves us with detach/attach (which is what Copy Database Wizard is using) and BACKUP/RESTORE.
> I prefer Backup/Restore as that don't affect the source database, and the amount of data to transfer
> is less (empty space isn't included in backup), I only get one file etc.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
>
> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> news:F6C87F0D-2BBD-40F8-90C4-9F9A40CFE0D4@.microsoft.com...
> > Hi, All,
> >
> > Import/Export, Copy Database Wizard, and Backup/Restore can copy sql 2000
> > data to sql 2005, can anyone know which is better way to upgrade sql 2000 to
> > 2005?
> >
> > Thanks,
> > Martin
> >
> > "Tibor Karaszi" wrote:
> >
> >> KB = Microsoft KnowledgeBase:
> >> http://support.microsoft.com/default.aspx?scid=fh;EN-US;kbhowto&sd=GN&=EN-US&FR=0
> >>
> >> --
> >> Tibor Karaszi, SQL Server MVP
> >> http://www.karaszi.com/sqlserver/default.asp
> >> http://www.solidqualitylearning.com/
> >>
> >>
> >> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> >> news:4CDECE99-FCEC-45AA-9090-B5CA8385C70C@.microsoft.com...
> >> > Thank you.
> >> >
> >> > as for sp_help_revlogin procedure from KB, what is KB?
> >> >
> >> > "Tibor Karaszi" wrote:
> >> >
> >> >> I suggest you use BACKUP and RESTORE to move the database. It is fully online. Also, get the
> >> >> sp_help_revlogin procedure from KB and use that to move over your login (this way the users'
> >> >> SID
> >> >> will match the login's SID).
> >> >>
> >> >> --
> >> >> Tibor Karaszi, SQL Server MVP
> >> >> http://www.karaszi.com/sqlserver/default.asp
> >> >> http://www.solidqualitylearning.com/
> >> >>
> >> >>
> >> >> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> >> >> news:E297ABCE-4F35-46CC-8BAC-98F803BA17B9@.microsoft.com...
> >> >> > Hi, All,
> >> >> >
> >> >> > I want to move sql 2000 db to sql 2005, including data and user. The sql
> >> >> > 2005 is on the remote server rather than local one. I knew using
> >> >> > import/export to move data, but don't know on how to move user info. Also
> >> >> > using copy database can copy 2000 to 2005, but before copy, need no
> >> >> > application and service to access 2000 db, so 1) how to make no application
> >> >> > and service access database? 2) anyone can tell detail procedure on how to
> >> >> > move?
> >> >> >
> >> >> > Thanks in advance for your time,
> >> >> > Martin
> >> >>
> >> >>
> >>
> >>
>|||The best thing would be detach and create for attach. I did the same for a
1.5TB database having 4 datafiles on multiple filegroups. It all went well
on SQL2005.
Note: You might have to run dbcc checkdb, dbcc updateusage after the
mgiration.
thks,
Manikanth.S
MCDBA.
"martin1" <martin1@.discussions.microsoft.com> wrote in message
news:37F7AE5F-69C0-4C67-9CF7-23320A3911F1@.microsoft.com...
> Thank you all for this help!
> Martin
> "Tibor Karaszi" wrote:
>> I believe that there has been some bugs in Copy Database Wizard. I've
>> only read about them, didn't
>> memorize them, but it was enough for me to avoid it. I'm sure MS has been
>> working on for sp2,
>> though.
>> I generally prefer working on the binary level (backup/restore or
>> detach/attach) instead of
>> Export/Import. When you use the later, the database is scripted (a bunch
>> of CREATE statements), the
>> script files are executed against the destination, and then the data is
>> transferred. If you aren't
>> prepared to handle any possible errors in the script handling (if it
>> isn't "your" data model"), then
>> I recommend against Export/Import.
>> That leaves us with detach/attach (which is what Copy Database Wizard is
>> using) and BACKUP/RESTORE.
>> I prefer Backup/Restore as that don't affect the source database, and the
>> amount of data to transfer
>> is less (empty space isn't included in backup), I only get one file etc.
>> --
>> Tibor Karaszi, SQL Server MVP
>> http://www.karaszi.com/sqlserver/default.asp
>> http://www.solidqualitylearning.com/
>>
>> "martin1" <martin1@.discussions.microsoft.com> wrote in message
>> news:F6C87F0D-2BBD-40F8-90C4-9F9A40CFE0D4@.microsoft.com...
>> > Hi, All,
>> >
>> > Import/Export, Copy Database Wizard, and Backup/Restore can copy sql
>> > 2000
>> > data to sql 2005, can anyone know which is better way to upgrade sql
>> > 2000 to
>> > 2005?
>> >
>> > Thanks,
>> > Martin
>> >
>> > "Tibor Karaszi" wrote:
>> >
>> >> KB = Microsoft KnowledgeBase:
>> >> http://support.microsoft.com/default.aspx?scid=fh;EN-US;kbhowto&sd=GN&=EN-US&FR=0
>> >>
>> >> --
>> >> Tibor Karaszi, SQL Server MVP
>> >> http://www.karaszi.com/sqlserver/default.asp
>> >> http://www.solidqualitylearning.com/
>> >>
>> >>
>> >> "martin1" <martin1@.discussions.microsoft.com> wrote in message
>> >> news:4CDECE99-FCEC-45AA-9090-B5CA8385C70C@.microsoft.com...
>> >> > Thank you.
>> >> >
>> >> > as for sp_help_revlogin procedure from KB, what is KB?
>> >> >
>> >> > "Tibor Karaszi" wrote:
>> >> >
>> >> >> I suggest you use BACKUP and RESTORE to move the database. It is
>> >> >> fully online. Also, get the
>> >> >> sp_help_revlogin procedure from KB and use that to move over your
>> >> >> login (this way the users'
>> >> >> SID
>> >> >> will match the login's SID).
>> >> >>
>> >> >> --
>> >> >> Tibor Karaszi, SQL Server MVP
>> >> >> http://www.karaszi.com/sqlserver/default.asp
>> >> >> http://www.solidqualitylearning.com/
>> >> >>
>> >> >>
>> >> >> "martin1" <martin1@.discussions.microsoft.com> wrote in message
>> >> >> news:E297ABCE-4F35-46CC-8BAC-98F803BA17B9@.microsoft.com...
>> >> >> > Hi, All,
>> >> >> >
>> >> >> > I want to move sql 2000 db to sql 2005, including data and user.
>> >> >> > The sql
>> >> >> > 2005 is on the remote server rather than local one. I knew using
>> >> >> > import/export to move data, but don't know on how to move user
>> >> >> > info. Also
>> >> >> > using copy database can copy 2000 to 2005, but before copy, need
>> >> >> > no
>> >> >> > application and service to access 2000 db, so 1) how to make no
>> >> >> > application
>> >> >> > and service access database? 2) anyone can tell detail procedure
>> >> >> > on how to
>> >> >> > move?
>> >> >> >
>> >> >> > Thanks in advance for your time,
>> >> >> > Martin
>> >> >>
>> >> >>
>> >>
>> >>
>>

move sql 2000 db to sql 2005

Hi, All,
I want to move sql 2000 db to sql 2005, including data and user. The sql
2005 is on the remote server rather than local one. I knew using
import/export to move data, but don't know on how to move user info. Also
using copy database can copy 2000 to 2005, but before copy, need no
application and service to access 2000 db, so 1) how to make no application
and service access database? 2) anyone can tell detail procedure on how to
move?
Thanks in advance for your time,
MartinI suggest you use BACKUP and RESTORE to move the database. It is fully onlin
e. Also, get the
sp_help_revlogin procedure from KB and use that to move over your login (thi
s way the users' SID
will match the login's SID).
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"martin1" <martin1@.discussions.microsoft.com> wrote in message
news:E297ABCE-4F35-46CC-8BAC-98F803BA17B9@.microsoft.com...
> Hi, All,
> I want to move sql 2000 db to sql 2005, including data and user. The sql
> 2005 is on the remote server rather than local one. I knew using
> import/export to move data, but don't know on how to move user info. Also
> using copy database can copy 2000 to 2005, but before copy, need no
> application and service to access 2000 db, so 1) how to make no applicati
on
> and service access database? 2) anyone can tell detail procedure on how t
o
> move?
> Thanks in advance for your time,
> Martin|||Thank you.
as for sp_help_revlogin procedure from KB, what is KB?
"Tibor Karaszi" wrote:

> I suggest you use BACKUP and RESTORE to move the database. It is fully onl
ine. Also, get the
> sp_help_revlogin procedure from KB and use that to move over your login (t
his way the users' SID
> will match the login's SID).
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
>
> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> news:E297ABCE-4F35-46CC-8BAC-98F803BA17B9@.microsoft.com...
>|||KB = Microsoft KnowledgeBase:
http://support.microsoft.com/defaul...ver/default.asp
http://www.solidqualitylearning.com/
"martin1" <martin1@.discussions.microsoft.com> wrote in message
news:4CDECE99-FCEC-45AA-9090-B5CA8385C70C@.microsoft.com...[vbcol=seagreen]
> Thank you.
> as for sp_help_revlogin procedure from KB, what is KB?
> "Tibor Karaszi" wrote:
>|||Thanks again
"Tibor Karaszi" wrote:

> KB = Microsoft KnowledgeBase:
> http://support.microsoft.com/defaul...US&FR=
0
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
>
> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> news:4CDECE99-FCEC-45AA-9090-B5CA8385C70C@.microsoft.com...
>|||Hi, All,
Import/Export, Copy Database Wizard, and Backup/Restore can copy sql 2000
data to sql 2005, can anyone know which is better way to upgrade sql 2000 to
2005?
Thanks,
Martin
"Tibor Karaszi" wrote:

> KB = Microsoft KnowledgeBase:
> http://support.microsoft.com/defaul...US&FR=
0
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
>
> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> news:4CDECE99-FCEC-45AA-9090-B5CA8385C70C@.microsoft.com...
>|||I believe that there has been some bugs in Copy Database Wizard. I've only r
ead about them, didn't
memorize them, but it was enough for me to avoid it. I'm sure MS has been wo
rking on for sp2,
though.
I generally prefer working on the binary level (backup/restore or detach/att
ach) instead of
Export/Import. When you use the later, the database is scripted (a bunch of
CREATE statements), the
script files are executed against the destination, and then the data is tran
sferred. If you aren't
prepared to handle any possible errors in the script handling (if it isn't "
your" data model"), then
I recommend against Export/Import.
That leaves us with detach/attach (which is what Copy Database Wizard is usi
ng) and BACKUP/RESTORE.
I prefer Backup/Restore as that don't affect the source database, and the am
ount of data to transfer
is less (empty space isn't included in backup), I only get one file etc.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"martin1" <martin1@.discussions.microsoft.com> wrote in message
news:F6C87F0D-2BBD-40F8-90C4-9F9A40CFE0D4@.microsoft.com...[vbcol=seagreen]
> Hi, All,
> Import/Export, Copy Database Wizard, and Backup/Restore can copy sql 2000
> data to sql 2005, can anyone know which is better way to upgrade sql 2000
to
> 2005?
> Thanks,
> Martin
> "Tibor Karaszi" wrote:
>|||Backup / restore is best, as it copies everything and gives you the ability
to save the intermediate state. The Copy Database Wizard is the easiest to
use, it also copies everything. Import/Export discards a lot of imformation
and is therefore not an option for copying whole databases.
If you are replacing SQL2000 with SQL2005, you can also just detach and
attach the files.
"martin1" <martin1@.discussions.microsoft.com> wrote in message
news:F6C87F0D-2BBD-40F8-90C4-9F9A40CFE0D4@.microsoft.com...[vbcol=seagreen]
> Hi, All,
> Import/Export, Copy Database Wizard, and Backup/Restore can copy sql 2000
> data to sql 2005, can anyone know which is better way to upgrade sql 2000
> to
> 2005?
> Thanks,
> Martin
> "Tibor Karaszi" wrote:
>|||Thank you all for this help!
Martin
"Tibor Karaszi" wrote:

> I believe that there has been some bugs in Copy Database Wizard. I've only
read about them, didn't
> memorize them, but it was enough for me to avoid it. I'm sure MS has been
working on for sp2,
> though.
> I generally prefer working on the binary level (backup/restore or detach/a
ttach) instead of
> Export/Import. When you use the later, the database is scripted (a bunch o
f CREATE statements), the
> script files are executed against the destination, and then the data is tr
ansferred. If you aren't
> prepared to handle any possible errors in the script handling (if it isn't
"your" data model"), then
> I recommend against Export/Import.
> That leaves us with detach/attach (which is what Copy Database Wizard is u
sing) and BACKUP/RESTORE.
> I prefer Backup/Restore as that don't affect the source database, and the
amount of data to transfer
> is less (empty space isn't included in backup), I only get one file etc.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
>
> "martin1" <martin1@.discussions.microsoft.com> wrote in message
> news:F6C87F0D-2BBD-40F8-90C4-9F9A40CFE0D4@.microsoft.com...
>|||The best thing would be detach and create for attach. I did the same for a
1.5TB database having 4 datafiles on multiple filegroups. It all went well
on SQL2005.
Note: You might have to run dbcc checkdb, dbcc updateusage after the
mgiration.
thks,
Manikanth.S
MCDBA.
"martin1" <martin1@.discussions.microsoft.com> wrote in message
news:37F7AE5F-69C0-4C67-9CF7-23320A3911F1@.microsoft.com...[vbcol=seagreen]
> Thank you all for this help!
> Martin
> "Tibor Karaszi" wrote:
>

Monday, February 20, 2012

move database

I'm working with an msde database on my local machine, but need to take that database and move it to my remote host. This is problematic because I can not just do a back up and restore.

I was wondering if there were any asp.net applications that would generate lots of sql statements to reproduce the database on my remote host.

I had built a program to back up all the tables in that way, but, forgot that the membership stuff uses stored procedures, and I don't not know how to modify my program in order to back those up too.

Any help will be much appreciated, thank you very much for reading my post

If you just want your stored procs and tables and other objects you could script out the entire DB and compile them at the destination DB. I am not sure if MSDE has that option. Right click on DB -> All Tasks -> Generate SQL Script.|||

woa, thats absolutly fantastic! But still only close. If I copy portions of statemetns at a time it will work, but Asp.net enterprise manager does not seem to like some of the keywords.

things like

CREATE PROCEDURE [dbo].[aspnet_Membership_GetUserByEmail] @.ApplicationNamenvarchar(256), @.Emailnvarchar(256)ASBEGIN IF( @.EmailISNULL )SELECT u.UserNameFROM dbo.aspnet_Applications a, dbo.aspnet_Users u, dbo.aspnet_Membership mWHERELOWER(@.ApplicationName) = a.LoweredApplicationNameAND u.ApplicationId = a.ApplicationIdAND u.UserId = m.UserIdAND m.LoweredEmailISNULLELSE SELECT u.UserNameFROM dbo.aspnet_Applications a, dbo.aspnet_Users u, dbo.aspnet_Membership mWHERELOWER(@.ApplicationName) = a.LoweredApplicationNameAND u.ApplicationId = a.ApplicationIdAND u.UserId = m.UserIdANDLOWER(@.Email) = m.LoweredEmailIF (@.@.rowcount = 0)RETURN(1)RETURN(0)END

works, but this will not


I noticed there are a bunch of options will in the wizard that generates the script. Is there a way to get rid all that extra stuff?

SET ANSI_NULLSONGOSET QUOTED_IDENTIFIEROFFGOIFNOT EXISTS (SELECT *FROM dbo.sysobjectsWHERE id =OBJECT_ID(N'[dbo].[aspnet_Membership_GetUserByEmail]')ANDOBJECTPROPERTY(id,N'IsProcedure') = 1)BEGINEXEC dbo.sp_executesql @.statement = N'CREATE PROCEDURE [dbo].[aspnet_Membership_GetUserByEmail] @.ApplicationName nvarchar(256), @.Email nvarchar(256)ASBEGIN IF( @.Email IS NULL ) SELECT u.UserName FROM dbo.aspnet_Applications a, dbo.aspnet_Users u, dbo.aspnet_Membership m WHERE LOWER(@.ApplicationName) = a.LoweredApplicationName AND u.ApplicationId = a.ApplicationId AND u.UserId = m.UserId AND m.LoweredEmail IS NULL ELSE SELECT u.UserName FROM dbo.aspnet_Applications a, dbo.aspnet_Users u, dbo.aspnet_Membership m WHERE LOWER(@.ApplicationName) = a.LoweredApplicationName AND u.ApplicationId = a.ApplicationId AND u.UserId = m.UserId AND LOWER(@.Email) = m.LoweredEmail IF (@.@.rowcount = 0) RETURN(1) RETURN(0)END'END

I noticed there were a bunch of options when generating the script, is there an option that will get rid of all that extra stuff?

I am trying to move more then one proceedure, I just showed one for an example

Thanks so much

|||does anyone have any experience with this, or have any alternative methods?|||What do you mean by ASP.NET Enterprise Manager? Do you want to use the generated scripts in VS2005 IDE? If so there are many limitations to the sql statements, e.g. SET/EXEC are not supported. The only option I found in the Script Wizard that will result in such differences between the 2 scripts you posted is 'Include IF NOT EXISTS' option.|||My web host uses ASP.NET enterprise manager.. its similiar to phpmyadmin, but for mssql|||'Include IF NOT EXISTS' only gets rid of some of stuff it seems.|||If you have access to Enterprise Manager quick and easy backup the database and restore it on your host server. Hope this helps.