Solved

SQL Loder

Posted on 2001-07-24
7
922 Views
Last Modified: 2008-03-10
I try to load a file in SQLLoader, but it gives me an error. Then when I try to change the file, I cannot have access to the file. Why is it so? Below is the things that I did. Thanks

$ loadInventory.sh

SQL*Loader: Release 7.3.2.2.0 - Production on Wed Jul 25 12:49:37 2001

Copyright (c) Oracle Corporation 1979, 1994.  All rights reserved.

SQL*Loader-350: Syntax error at line 5.
Expecting valid column specification, "," or ")", found "varchar2".
(CODE   position(01:08) varchar2,
                      ^
$ vi loadInventory.sh
"/ext1/app/oracle/product/7.3.2.2/tmp/Ex25775" Permission denied
0
Comment
Question by:rac13
7 Comments
 
LVL 2

Expert Comment

by:Kong
Comment Utility
Instead of varchar2 use char
0
 
LVL 2

Expert Comment

by:ddandekar
Comment Utility
For position based parameters for SQL Loader the column specification would be char and not varchar2.

Perhaps you can copy the .sh file in your directory and edit it before using.
0
 
LVL 2

Accepted Solution

by:
jbever earned 15 total points
Comment Utility
Hi Rac13

SQLloader only knows CHAR, Integer external, Decimal external and DATA data types.

So you need to user CHAR instead of varchar2.

J.
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 

Author Comment

by:rac13
Comment Utility
Now I had this error:

SQL*Loader: Release 7.3.2.2.0 - Production on Wed Jul 25 15:09:45 2001

Copyright (c) Oracle Corporation 1979, 1994.  All rights reserved.

SQL*Loader-350: Syntax error at line 5.
Expecting valid column specification, "," or ")", found "number".
QTY     position(15:19) number)
0
 
LVL 2

Expert Comment

by:jbever
Comment Utility
as i mentioned before:

SQLloader only knows CHAR, Integer external, Decimal external and DATA data types.

so now go for the integer external.

jan.
0
 

Author Comment

by:rac13
Comment Utility
Thanks, jbever had given me an answer closer to my problems so I decided to give hom the points. Thanks everyone. :)
0
 

Author Comment

by:rac13
Comment Utility
Hi jbever,
 
  can we insert word directly using SQLLoader?
Example:
load Data
infile 'tepl_stock.txt'
APPEND into table EXCEPTION
(SKU   position(01:10) char,
QTY     position(18:24) integer external,
REASON char REASON = "Cannot find the cross-reference STMS stock-code")
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Join & Write a Comment

Configuring and using Oracle Database Gateway for ODBC Introduction First, a brief summary of what a Database Gateway is.  A Gateway is a set of driver agents and configurations that allow an Oracle database to communicate with other platforms…
From implementing a password expiration date, to datatype conversions and file export options, these are some useful settings I've found in Jasper Server.
This video explains at a high level with the mandatory Oracle Memory processes are as well as touching on some of the more common optional ones.
This video shows how to configure and send email from and Oracle database using both UTL_SMTP and UTL_MAIL, as well as comparing UTL_SMTP to a manual SMTP conversation with a mail server.

771 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

10 Experts available now in Live!

Get 1:1 Help Now