Home » RDBMS Server » Server Utilities » SQL*Loader-350: Syntax error at line 12 (Oracle 10g SQL*Loader: Release 10.1.0.5.0)
icon8.gif  SQL*Loader-350: Syntax error at line 12 [message #356363] Thu, 30 October 2008 09:00 Go to next message
pg08662
Messages: 2
Registered: October 2008
Junior Member
I'm trying to load a txt/dat file into the table and it gives me an error
SQL*Loader-350: Syntax error at line 12.
Token longer than max allowable length of 258 chars
EFFECTIVE_DATE position(11:18) date,'YYYYMMDD'

Please help me!

LOAD DATA
INFILE '/export/home/oracle/import/PFPC_BENEFITS.dat
TRUNCATE
INTO TABLE PFPC_HR_BENEFITS
FIELDS TERMINATED BY ","
OPTIONALLY ENCLOSED BY '"' TRAILING NULLCOLS
WHEN (01:02)=98
(
TRANSACTION_CODE position(1:2) char,
SOURCE_SYS_MN position(3:5) char,
BUSINESS_UNIT position(6:10) integer external,
EFFECTIVE_DATE position(11:18) date,'YYYYMMDD'
--FILLER position(19:94) char
)
---INTO TABLE PFPC_HR_BENEFITS
---WHEN (01:02)<>98
--- (
---TRANSACTION_CODE position(1:2) char,
---SOURCE_SYS_MN position(3:5) char,
---BUSINESS_UNIT position(6:10) char,
---ACCOUNT_NUM position(11:18)char,
---COST_CENTER position(19:24) char,
---INTERCOMP_BUSINESS_UNIT position(25:29) char,
---DOCUMENT_NUM position(30:38) char,
---TRANSACTION_AMNT position(39:54) char,
---DESCRIPTION position(55:94) char,
---FILLER constant " "
---)
Re: SQL*Loader-350: Syntax error at line 12 [message #356376 is a reply to message #356363] Thu, 30 October 2008 09:39 Go to previous messageGo to next message
S.Rajaram
Messages: 1027
Registered: October 2006
Location: United Kingdom
Senior Member
Welcome to the forum. Please format your post from next time. For how to do it read the forum guidelines.
Quote:

INFILE '/export/home/oracle/import/PFPC_BENEFITS.dat


You have missed to close the infile. Also check this link how to give a format mask for a date field

http://download.oracle.com/docs/cd/B19306_01/server.102/b14215/ldr_field_list.htm#sthref1012

Hope this helps.

Regards

Raj

[Updated on: Thu, 30 October 2008 09:41]

Report message to a moderator

icon12.gif  Re: SQL*Loader-350: Syntax error at line 12 [message #356383 is a reply to message #356376] Thu, 30 October 2008 10:10 Go to previous message
pg08662
Messages: 2
Registered: October 2008
Junior Member
Raj, thank you nery much, it worked.

Kristina
Previous Topic: importing from 9i (windows) to 10g (h-ux 11.3)
Next Topic: sqlldr - Skip header in all Infiles
Goto Forum:
  


Current Time: Wed May 01 01:48:15 CDT 2024