cancel
Showing results for 
Search instead for 
Did you mean: 

Bulk data loading into tables.

N/A

Bulk data loading into tables.

Probably a bit of an “old chestnut” of a question, but being relatively new to databases, SQL & PHP I would like one, hopefully quite simple question answered:

Is there a way to bulk load data into a table? & if so how.

Thank you for any help.

JD
2 REPLIES
espresso_mick
Grafter
Posts: 225
Registered: 30-07-2007

RE: Bulk data loading into tables.

You need to use the utility 'sql*loader'.
Check out the following link for a complete guide to using it.

http://www.orafaq.com/faqloadr.htm

Mick
N/A

RE: Bulk data loading into tables.

> databases, SQL & PHP...

Just in case you meant MySQL then "PHP and MySQL Web Development" by Luke Welling and Laura Thomson, published by SAMS, says:

"Loading Data from a File

One useful feature of MySQL....is the LOAD DATA INFILE statement. This can be used to load table data in from a file. It executes very quickly.

This is a flexible command with many options, but typical usage is something like the following:

LOAD DATA INFILE "newbooks.txt" INTO TABLE books;

This will read row data from the file newbooks.txt into the table books. By default, data fields in the file must be separated by tabs and enclosed in single quotes, and each row must be separated by a newline (\n). Special characters must be escaped out with a slash (\). All these characteristics are configurable with the various options of the LOAD statement - see the MySQL manual for more details.

To use the LOAD DATA INFILE statement, a user must have the FILE privilege...."

and

"If you want to know more, particularly with regard to non-Web applications, or MySQL administration, you can visit the MySQL Web site at

http://www.mysql.com";

Hope this is useful...
Tim