Home » RDBMS Server » Server Utilities » FIELDS TERMINATED BY ","; NEED MISS "\," simboll
FIELDS TERMINATED BY ","; NEED MISS "\," simboll [message #210499] Thu, 21 December 2006 02:14 Go to next message
nmomtselidze
Messages: 3
Registered: December 2006
Junior Member
Hi,
In SQL*Loader CTL FIELDS are TERMINATED BY ",".
But same loading fields have symbols "\," as parts
of data fields. Have any possibility to avoid
field termination by "\,".
This symbol is not enclosed by "".
Raw example:
198.18.8.1,http://kiss.best.su/?best\,star\,step2\,\,353456c2\,,,39,0,[/url]
Part of ctl file:
........
INTO TABLE TEMPLOG
FIELDS TERMINATED BY ","
TRAILING NULLCOLS
(
nampServerIPaddress ,
fetchedURL ,
originalURL ,
.......
Help me,please
Thank you
Re: FIELDS TERMINATED BY ","; NEED MISS "\," simboll [message #210523 is a reply to message #210499] Thu, 21 December 2006 03:39 Go to previous messageGo to next message
tahpush
Messages: 961
Registered: August 2006
Location: Stockholm/Sweden
Senior Member

1. I cant use the url - you are providing
2. You dont want to load the "\" sign into your database,
is that the question ?

You have to be describe your problem a bit better......
Show an example of the data you want to load as well....
Re: FIELDS TERMINATED BY ","; NEED MISS "\," simboll [message #210565 is a reply to message #210523] Thu, 21 December 2006 06:02 Go to previous messageGo to next message
nmomtselidze
Messages: 3
Registered: December 2006
Junior Member
Thank you,
The loading data are pumped from Nokia station.
198.18.8.1,http://kiss.best.su/?best\,star\,step2\,\,353456\,,,39,0,...
CTL:
FIELDS TERMINATED BY ","
(
nampServerIPaddress ,
fetchedURL ,
originalURL ,
.......
This data from comma to comma have to be written to fields
but not \,. It is C like char of comma, not terminator.

198.18.8.1 => nampServerIPaddress
http://kiss.best.su/?best\,star\,step2\,\,353456\, => fetchedURL
null => originalURL
39 => ... and so on.
........
So the problem is that "\," is not field terminator, only "," is.
I need comma as part of field.

Other examples:
198.18.8.1,http://beeline.mmska.ru/pay/6631429655/\,order\,8063,,0,0,
198.18.8.1,http://free.wapstart.ru/pics/item/g_id\,1\,i_id\,17?wsf=cae6406538383cbb15cc3e86e1ab251d,,515,0,

Thank you very much
Re: FIELDS TERMINATED BY ","; NEED MISS "\," simboll [message #210579 is a reply to message #210565] Thu, 21 December 2006 06:40 Go to previous messageGo to next message
tahpush
Messages: 961
Registered: August 2006
Location: Stockholm/Sweden
Senior Member

Why isnt the fields seperated with ; or |
Would be easier for you then.....

Have you looked into using external tables ?

[Updated on: Thu, 21 December 2006 06:40]

Report message to a moderator

Re: FIELDS TERMINATED BY ","; NEED MISS "\," simboll [message #210608 is a reply to message #210579] Thu, 21 December 2006 09:08 Go to previous messageGo to next message
nmomtselidze
Messages: 3
Registered: December 2006
Junior Member
Thank you,
Input data are comming from different switching stations,
and are constructed with the program which is beyond reach.
So I can not change it's stucture.
Moreover, they are tremendous large.
Extra revision takes a lot of time.
So I forced to use DIRECT loading which excludes
any additional processing while loading.
Most likely, I have to write some preprocessor to
avoid this problem.
Is it possible, there is some unreported opportunity,
like TERMINATED BY "," and NOT TERMINATED BY "\,"
or samthing like that?

Thank you anyway
Re: FIELDS TERMINATED BY ","; NEED MISS "\," simboll [message #210663 is a reply to message #210608] Thu, 21 December 2006 12:36 Go to previous message
joy_division
Messages: 4963
Registered: February 2005
Location: East Coast USA
Senior Member
In your controlfile, can you not do this on every column:
column1 "substr(:column1,1,length(:column1)-1)"
Previous Topic: Load first 2000 characters using SQL LOADER
Next Topic: Not import the file
Goto Forum:
  


Current Time: Wed Jun 26 13:55:28 CDT 2024