Hi Witold :

        You should, to create an function "divide" : divide(12345/100)
result = 123.45
In ControlFile you should include the following sentence :

LOAD DATA
TRUNCATE
PRESERVE BLANKS
INTO TABLE TABLENAME
(
FIELD1          POSITION (1:20) CHAR,
FIELD2          POSITION (21:21) DECIMAL EXTERNAL,
FIELD3          FILLER  POSITION (22:26) DECIMAL EXTERNAL,
FIELD4          "DIVIDE(:FIELD3)"
)



-----Original Message-----
Sent: Tuesday, March 12, 2002 02:42 PM
To: Multiple recipients of list ORACLE-L


Hello

There are few numeric formats when you load data from a file. I am 
looking for a way, if possible, to load a number from a field that doesn't 
have the decimal point. 
For example I may know that in my five-character field the first three 
characters always represent the most-significant digits and the last two 
are always the decimal values. Something like:

field  12345
would be loaded as 123.45

If, in data file, I have the value 123.45 I can use decimal external but 
wonder if I can avoid the decimal point in datafile. How can I define the 
field in control file?

Thanks

Witold
==================================
Witold Iwaniec
Sr Software Developer
NovaLIS Technologies
[EMAIL PROTECTED]
http://www.novalistech.com

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Witold Iwaniec
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Gustavo Coria
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

Reply via email to