Solved

SQL Loader - Tab delimited

Posted on 2001-06-29
6
2,924 Views
Last Modified: 2011-09-20

I want to use sql loader to load a tab delimited files. How do I specify "TAB" in the sql loader control file? What do I put in the "???" in the line below?

FIELDS TERMINATED BY "???" OPTIONALLY ENCLOSED BY '"'

Thanks.
0
Comment
Question by:jyhuang
6 Comments
 
LVL 3

Accepted Solution

by:
myerpz earned 50 total points
ID: 6238254
While editing the control file, I entered a tab
between the quotes after 'terminated by' and
that worked for me.

Hope this helps.
0
 
LVL 1

Expert Comment

by:dbrower
ID: 6238293
One of these should work

FIELDS TERMINATED BY WHITESPACE


FIELDS TERMINATED BY '    '
where the space between the quotes is a Tab

Good luck
0
 
LVL 1

Expert Comment

by:bkm
ID: 6238320
Hope this helps!!

LOAD DATA
INFILE 'files.txt'
INTO TABLE files
INSERT
FIELDS TERMINATED BY X'09' TRAILING NULLCOLS
(ID_FILE,
NATION,
PATENT,
TITLE,
HKEY)

Another Eg:

LOAD DATA

   INFILE 'FILENAME.TXT'

   INTO TABLE t1

   FIELDS DELIMITED BY x'09'

   TRAILING NULLCOLS

     ( column 1....

     )

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.

 
LVL 35

Expert Comment

by:Mark Geerlings
ID: 6238372
Since "chr(09)" works to insert a tab character, it may work in SQL*Loader as well (but I haven't tried it) like this:
FIELDS TERMINATED BY chr(09)
0
 
LVL 3

Expert Comment

by:jaramill
ID: 6239128
Also add after each column

(column_name1   datatype TERMINATED BY X'09',
 column_name2   datatype TERMINATED BY X'09')

Gio
0
 
LVL 1

Author Comment

by:jyhuang
ID: 6239244
Thank you all for your responses. Almost all your suggestions are working. I can use space, tab, or X'09'. But since myerpz is the first one who gave the correct answer, I am giving the points to him/her.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Encryption Decryption in Oracle 12 102
statspack purge automate 7 49
oracle rollup query 3 50
Oracle - SQL Parse String 5 15
Article by: Swadhin
From the Oracle SQL Reference (http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/queries006.htm) we are told that a join is a query that combines rows from two or more tables, views, or materialized views. This article provides a glimps…
Subquery in Oracle: Sub queries are one of advance queries in oracle. Types of advance queries: •      Sub Queries •      Hierarchical Queries •      Set Operators Sub queries are know as the query called from another query or another subquery. It can …
Via a live example show how to connect to RMAN, make basic configuration settings changes and then take a backup of a demo database
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.

947 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

22 Experts available now in Live!

Get 1:1 Help Now