Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
apociecha
Starting Member
17 Posts |
Posted - 2003-05-02 : 18:15:30
|
| I wondered if anyone can help me understand this minor issue.I created a table on my local SQL Server with decimal fields and when I exported this table to a different SQL Server, the fields came over as numeric. The precision and scale where the same, but I don't know why SQL Server chose numeric in my destination table.Thanks,Agnes |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2003-05-02 : 18:45:22
|
| SQL Server Books Online says "numeric is functionally equivalent to decimal". How did you do the export? What tool did you use? If it was DTS, then just create the table manually on the destination server, then just transfer the data (don't have it create the table for you). But BOL says they are the same, so it shouldn't matter which data type it is.Tara |
 |
|
|
apociecha
Starting Member
17 Posts |
Posted - 2003-05-02 : 18:51:00
|
| Thanks very much for your quick reply.I did find that the two data types are the same, I just wondered if anyone knew why SQL Server chose a data type different than the source table. I'm actually moving about 35 tables, so I was hopingto make the export do the table creation work for me.The export was done straight through Enterprise Manager, which leads me to a question. What is a good method for migrating a database, inclusive of diagrams, stored procedures, views and tables, from one SQL Server to another?Agnes |
 |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2003-05-02 : 19:01:00
|
| Use the detach/attach stored procedures or run BACKUP/RESTORE. Most people will recommend detach/attach if you are copying a non-production database because the detach will take the database offline.Here is an article that should help you out:[url]http://databasejournal.com/features/mssql/article.php/1439831[/url]You could also use the Copy Database Wizard, but I don't recommend that (I don't usually recommend wizards because they don't help you learn the technology).TaraEdited by - tduggan on 05/02/2003 19:01:48 |
 |
|
|
apociecha
Starting Member
17 Posts |
Posted - 2003-05-05 : 09:27:28
|
| My apologies for the late response, but I just wanted to say thank you for the information, it is much appreciated.And, in general, I find the forums on this site EXCELLENT.Thanks again,Agnes |
 |
|
|
|
|
|
|
|