Solved

loading data to a SQL server

Posted on 1998-07-02
7
259 Views
Last Modified: 2010-03-19
I have created a database and its devices in the SQL server, I need to populate data into this server. I have this data in a file at a different server, how can I transfer this data (just the data) into my database.
0
Comment
Question by:khal
  • 2
  • 2
  • 2
  • +1
7 Comments
 

Accepted Solution

by:
peterprice earned 40 total points
ID: 1091646
Use a piece of software such as access/vb3 that can access the remote database via either ODBC through its own SQL or by sending natively. then use the software to read the flat file (I assume that is what you mean) and issue inserts to the database.
0
 

Author Comment

by:khal
ID: 1091647
could you explain more please? and is the insert command going to be implemented on each table !!(I have a huge database)
0
 
LVL 7

Expert Comment

by:spiridonov
ID: 1091648
If you want the simpliest soluution, use Access,  but  using ODBC to load huge amount of data could take hours. If you need performance,you should use SQL Server own facility, which will be several times faster. Difference can be more then 10 times.
0
What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

 
LVL 1

Expert Comment

by:jboyd
ID: 1091649
If you want I can send you a BCP program that we have written to transfer data directly from one Sybase/MS SQL Server to another Sybase/MS SQL Server. It is much faster than having to BCP out to a file then BCP back in from a file. We usually build a batch file to call this EXE for each table by selecting all the tables in sysobjects.
0
 

Author Comment

by:khal
ID: 1091650
I am using Transact SQL, does your BCP program support that? if yes please send me this program, I would like to have it, thanks.
0
 
LVL 7

Expert Comment

by:spiridonov
ID: 1091651
BCP is installed with  SQL Server.
0
 
LVL 1

Expert Comment

by:jboyd
ID: 1091652
It does come with SQL Server, but you must BCP out to a file then in from a file. My program BCPs from server to server, no file involved, cutting the time in half. You can also specify the actual select statement from the source server so you can change the order of columns or actually BCP a subset of columns from one table into another table. Quite helpfull for removing a column from a table, and quickly moving the data. I am making some minor changes to the program right now, but I will try to e-mail it out in the next few days.
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Nowadays, some of developer are too much worried about data. Who is using data, who is updating it etc. etc. Because, data is more costlier in term of money and information. So security of data is focusing concern in days. Lets' understand the Au…
Introduction In my previous article (http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/SSIS/A_9150-Loading-XML-Using-SSIS.html) I showed you how the XML Source component can be used to load XML files into a SQL Server database, us…
Via a live example combined with referencing Books Online, show some of the information that can be extracted from the Catalog Views in SQL Server.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now