Questions tagged [sql-loader]

SQL*Loader is a high-speed data loading utility that loads data from external files into tables in an Oracle database.

SQL*Loader is a high-speed data loading utility that loads data from external files into tables in an Oracle database. SQL*Loader accepts input data in a variety of formats, can perform filtering, and can load data into multiple Oracle database tables during the same load session.

Source: http://www.oracle.com/technetwork/database/enterprise-edition/index-093639.html

1010 questions
40
votes
7 answers

Oracle: Import CSV file

I've been searching for a while now but can't seem to find answers so here goes... I've got a CSV file that I want to import into a table in Oracle (9i/10i). Later on I plan to use this table as a lookup for another use. This is actually a…
cr8ivecodesmith
  • 2,021
  • 5
  • 21
  • 30
23
votes
5 answers

Oracle sqlldr TRAILING NULLCOLS required, but why?

I have an abstruse sqlldr problem that's bothering me. My control file looks something like this: load data infile 'txgen.dat' into table TRANSACTION_NEW fields terminated by "," optionally enclosed by '"' TRAILING NULLCOLS ( A, B, C, D, ID…
orbfish
  • 7,381
  • 14
  • 58
  • 75
21
votes
8 answers

Disable and later enable all table indexes in Oracle

How would I disable and later enable all indexes in a given schema/database in Oracle? Note: This is to make sqlldr run faster.
oneself
  • 38,641
  • 34
  • 96
  • 120
20
votes
5 answers

Is there any way to use a strftime-like function for dates before 1900 in Python?

I didn't realize this, but apparently Python's strftime function doesn't support dates before 1900: >>> from datetime import datetime >>> d = datetime(1899, 1, 1) >>> d.strftime('%Y-%m-%d') Traceback (most recent call last): File "", line…
Jason Baker
  • 192,085
  • 135
  • 376
  • 510
14
votes
4 answers

How to populate a timestamp field with current timestamp using Oracle Sql Loader

I'm reading a pipe delimited file with SQL Loader and want to populate a LAST_UPDATED field in the table I am populating. My Control File looks like this: LOAD DATA INFILE SampleFile.dat REPLACE INTO TABLE contact FIELDS TERMINATED BY…
Sen
  • 327
  • 1
  • 3
  • 11
11
votes
8 answers

Is it possible for Oracle sqlldr to accept a TNS entry as an instance qualifier in Oracle 10 and 11?

Is it possible to use a fully qualified TNS entry using sqlldr bundled with Oracle 10/11? For example, in SQLPlus: sqlplus user/password@(description=(address=(host=localhost)(protocol=tcp)(port=1521))(connect_data=(sid=orcl))) @script.sql But…
BitPusher
  • 990
  • 1
  • 9
  • 20
11
votes
1 answer

Oracle sqlldr timestamp format headache

I'm struggling to get sqlldr to import a csv data file into my table, specifically with the field that is a timestamp. The data in my csv file is in this format: 16-NOV-09 01.57.48.001000 PM I've tried all manner of combinations in my control file…
Kevin
  • 11,521
  • 22
  • 81
  • 103
9
votes
2 answers

Oracle Sql Loader "ORA-01722: invalid number" when loading CSV file with Windows line endings

I am using Oracle Sql Loader Utility from Linux shell to load csv data into Oracle DB. But I have noticed that if source csv files lines endings are '\r\n' (Windows format), sqlldr fails to load data for last column. For example, if last column is…
daniilyar
  • 2,602
  • 3
  • 22
  • 25
9
votes
5 answers

load multiple csv into one table by SQLLDR

I am using SQL LOADER to load multiple csv file in one table. The process I found is very easy like LOAD DATA INFILE '/path/file1.csv' INFILE '/path/file2.csv' INFILE '/path/file3.csv' INFILE '/path/file4.csv' APPEND INTO TABLE…
goldenbutter
  • 575
  • 2
  • 12
  • 25
9
votes
2 answers

SQL Loader Error: "Variable length field exceeds maximum length."

I have a SQL Loader Control file, LOAD DATA INFILE 'test.txt' INTO TABLE TEST replace fields terminated "|" optionally enclosed by '"' TRAILING NULLCOLS ( DOCUMENTID INTEGER(10), CUSTID INTEGER(10), USERID INTEGER(10), FILENAME…
tjsimmons
  • 733
  • 4
  • 10
  • 21
8
votes
1 answer

OracleBulkCopy vs SQL*Loader Performance

I am seeing some significant performance differences between OracleBulkCopy (ODP.NET) and SQL*Loader when the Oracle server is on another machine. I have a very basic table in Oracle with three columns (one BINARY_FLOAT, two NUMBER(18,0)). There are…
Adrian Brown
  • 250
  • 3
  • 9
8
votes
2 answers

Oracle Sql Loader skip option for multiple infiles

When using SQL Loader control file as following: OPTIONS(**skip=1**,bindsize=1048576,rows=1024) LOAD DATA INFILE 'C:\Documents and Settings\FIRST.CSV' INFILE 'C:\Documents and Settings\SECOND.CSV' APPEND INTO TABLE table_name FIELDS TERMINATED BY…
reforrer
  • 735
  • 7
  • 13
  • 18
8
votes
3 answers

Install sql loader linux

I tried to install Oracle instant client on a redhat machine. I have instantClient basic, sdk, and sqlplus but I could not find any sqlldr. Can some one help me do it? Thanks
Masih
  • 1,633
  • 4
  • 19
  • 38
8
votes
1 answer

Skipping data fields while loading delimited data using SQLLDR

Consider below scenario: Table T1 (f1, f2, f3); Data files: a|b|c|d w|x|y|z I want to load this data skipping the second field as follow: f1 f2 f3 --- --- --- a d c w z y Would really appreciate your help or any…
Vinod Yadav
  • 359
  • 1
  • 5
  • 13
7
votes
3 answers

Field in data file exceeds maximum length - error

when i am trying to insert data in to a column of size varchar2(4000) in table i am getting error as "Field in data file exceeds maximum length". the data =…
user3195273
  • 193
  • 1
  • 5
  • 13
1
2 3
67 68