In MySQL, I use "LOAD DATA INFILE 'my_path/data_file.txt'" to load data
from a plain text file. Of course, the actual statement is a bit more
complex once one considers the various options (e.g. comma delimited vs
tab delimited, record termination strings, &c.).
My problem is that I have yet to find the equivalent within MS SQL
server. I did find a LOAD statement in T-SQL, but at first glance it
seems to do something completely different.
How does one normally load data from a plain text file into a table in
MS SQL? This needs to be relatively efficient since, once in
production, it will be used to load tens of megabytes of data into the
database (a feed from a data provider). Is it flexible enough to allow
me to specify whether the fields are tab delimited vs comma delimited,
optionally enclosed by quotes, record termination charactors, &c.?
All I really need is direction to the right part of the T-SQL reference
(MS SQL Server 2005). Anything else, such as examples, is icing on the
cake.
Thanks
Ted 2 3804
On 3 Aug 2006 17:53:42 -0700, "Ted" <r.*********@rogers.comwrote:
>In MySQL, I use "LOAD DATA INFILE 'my_path/data_file.txt'" to load data from a plain text file. Of course, the actual statement is a bit more complex once one considers the various options (e.g. comma delimited vs tab delimited, record termination strings, &c.).
My problem is that I have yet to find the equivalent within MS SQL server. I did find a LOAD statement in T-SQL, but at first glance it seems to do something completely different.
How does one normally load data from a plain text file into a table in MS SQL? This needs to be relatively efficient since, once in production, it will be used to load tens of megabytes of data into the database (a feed from a data provider). Is it flexible enough to allow me to specify whether the fields are tab delimited vs comma delimited, optionally enclosed by quotes, record termination charactors, &c.?
All I really need is direction to the right part of the T-SQL reference (MS SQL Server 2005). Anything else, such as examples, is icing on the cake.
I believe you're looking for SQL Server Integration Services (formerly
Data Transformation Services for SQL 2000).
Look at the external bcp utility command.
T-SQL command BULK INSERT
And as stated in the other reply SQL Server Integration Services.
Tim S
"Ted" <r.*********@rogers.comwrote in message
news:11**********************@m73g2000cwd.googlegr oups.com...
In MySQL, I use "LOAD DATA INFILE 'my_path/data_file.txt'" to load data
from a plain text file. Of course, the actual statement is a bit more
complex once one considers the various options (e.g. comma delimited vs
tab delimited, record termination strings, &c.).
My problem is that I have yet to find the equivalent within MS SQL
server. I did find a LOAD statement in T-SQL, but at first glance it
seems to do something completely different.
How does one normally load data from a plain text file into a table in
MS SQL? This needs to be relatively efficient since, once in
production, it will be used to load tens of megabytes of data into the
database (a feed from a data provider). Is it flexible enough to allow
me to specify whether the fields are tab delimited vs comma delimited,
optionally enclosed by quotes, record termination charactors, &c.?
All I really need is direction to the right part of the T-SQL reference
(MS SQL Server 2005). Anything else, such as examples, is icing on the
cake.
Thanks
Ted This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: cmars |
last post by:
Hi,
I want to insert massive amounts of data in near real-time into a MySQL database. The data is in a structured binary format, and I have code that parses the data into logical data structures.
...
|
by: Ram |
last post by:
We are trying to load text tab delimited files into SQL server using
informatica 5.1 version. The text files are FTPed to a local server
and then files are moved to applicable folder before...
|
by: Mike Husler |
last post by:
We tried to load a file that contained 1 column of datetimes of the format
yyyy-MM-dd hh:mm:ss into a table that had the column set as a datetime type.
We did this using a DTS package. The error...
|
by: ozzy.osborn |
last post by:
Hello All,
I have been struggling with a cross browser solution to loading
external javascript files on the fly.
I have been successful using the following code in IE6:
var newScr =...
|
by: jhoff |
last post by:
So, I'm in a pickle...
Lets say I have a page: http://www.gen2host.com/discgolf/index.html
and on this page, there are a list of links. These links will be
generated by 5 pieces of data pulled...
|
by: Venkatesh |
last post by:
Hello All,
I have couple of doubts regarding the concept of on-demand javascript
loading using javascript code. I could see on the net different
techniques for achieving this - techniques like:...
|
by: yeoj13 |
last post by:
Hello,
I have a db2load script I'm using to populate a large table.
Ideally, my target table is required to have "Not Null" constraints on
a number of different columns.
I've noticed a ...
|
by: NickW |
last post by:
I have written a stored procedure that is used to load data into a SQL Server 2000 and 2005 databases from some 40ish different text files. One of the text files is loading all of the rows apart from...
|
by: pdhb_1 |
last post by:
I'm trying to run Apache2.2.6 with php. However, I keep getting a long
list of error messages in the log file indicating that includes are
failing. For example,
"PHP Warning: PHP Startup:...
|
by: igor.tatarinov |
last post by:
Hi, I am pretty new to Python and trying to use it for a relatively
simple problem of loading a 5 million line text file and converting it
into a few binary files. The text file has a fixed format...
|
by: DolphinDB |
last post by:
Tired of spending countless mintues downsampling your data? Look no further!
In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM).
In this month's session, we are pleased to welcome back...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM).
In this month's session, we are pleased to welcome back...
|
by: Vimpel783 |
last post by:
Hello!
Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
|
by: jfyes |
last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
|
by: CloudSolutions |
last post by:
Introduction:
For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
|
by: Defcon1945 |
last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
|
by: Shællîpôpï 09 |
last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
|
by: Faith0G |
last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
| |