Sqlload for decimal values

Hi,
I am having a problem.. the decimal values that I have on flat file is not upload to a table properly
Table
==============================
SQL> desc intfc_splitfactor
Name Null? Type
UDC_DIVISION VARCHAR2(50)
DMDUNIT VARCHAR2(30)
ITEM VARCHAR2(30)
LOC VARCHAR2(10)
EFFDATE DATE
QTY NUMBER(20,5)
SPLIT_FACTOR NUMBER(20,5)
Control File
================
LOAD DATA
INTO TABLE scpodintfc.intfc_splitfactor
APPEND
TRAILING NULLCOLS
UDC_DIVISION CHAR TERMINATED BY ",",
DMDUNIT CHAR TERMINATED BY ",",
ITEM CHAR TERMINATED BY ",",
LOC CHAR TERMINATED BY ",",
EFFDATE DATE 'MM/DD/YYYY' TERMINATED BY ",",
QTY DECIMAL EXTERNAL TERMINATED BY ",",
SPLIT_FACTOR DECIMAL EXTERNAL
datafile
===============
2,1103,110308PM,LO,07/02/2006,1026,0.25
2,1103,110308PM,LO,07/30/2006,2916,0.5
2,1103,110308PM,LO,08/27/2006,8007,0.4
2,1103,110308PM,LO,10/01/2006,3750,0.297
2,1103,110308PM,LO,10/29/2006,873,0
2,1103,110308PM,LO,11/26/2006,349,0
2,1103,110308PM,LO,12/31/2006,482,0.5
2,1103,110308PM,LO,01/28/2007,539,0.4
2,1103,110308PM,LO,02/25/2007,3906,0.5
2,1103,110308PM,LO,04/01/2007,12148,0.4
2,1103,110308PM,LO,04/29/2007,7574,0.4
2,1103,110308PM,LO,05/27/2007,4536,0
2,1103,110308PM,LO,07/01/2007,1763,0
2,1114,11148PM,LO,07/02/2006,632,0
===================================
after inserting
===================================
select SPLIT_FACTOR from intfc_splitfactor
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
.00
Can any one help to resolve this issue!!
Thanks
Indraneel

You could restructure you control file to:
LOAD DATA
INTO TABLE scpodintfc.intfc_splitfactor
APPEND
fields termianted by ","
TRAILING NULLCOLS
UDC_DIVISION     CHAR,
DMDUNIT          CHAR,
ITEM          CHAR,
LOC          CHAR,
EFFDATE          DATE 'MM/DD/YYYY',
QTY          DECIMAL EXTERNAL,
SPLIT_FACTOR     DECIMAL EXTERNAL
)

Similar Messages

  • Leading Zeros for Decimal values

    Hi,
    In my requirement i need to add leading zeros for Decimal values.
    For Example.
    If the value is = 0.00 then my Target value should be = 000000000000.00
    Regards,
    Anil.

    Hi Anil,
    You have to use conversion exit ,
    Kindly go through this link below:
    Re: Conversion exit: numbers in database, two decimals on screen
    Hope it helps
    Regards
    Mansi

  • How to get the leading zeros for decimal values?

    Hi,
      How i wil get the leading zeros for decimal values.For CONVERSION_EXIT_ALPHA_INPUT it is not working.Now iam using overlay condition for getting leading zeros.But iam getting the value like 00013.500.But as per my requirement i want to display this value 0000013.5.
    my code is
                    overlay w_MetLife_detail-rdempsalary with '000000000'
                    data :rdempsalary     type char9
    Please help me on this.
    Regards,
    Sujan

    Hi
    For more info,
    The function of the statement UNPACK is based on the fact, that the BCD display of a decimal place corresponds to the second half-byte of code of a digit in the most character representations. This conversion is commonly called "unpacking".
    The statement PACK to pack is obsolete and can be replaced by MOVE.
    If destination is specified as untyped field symbol or as untyped formal parameter and is not flat and not character-type during execution of the statement, then an untreatable exception occurs in Unicode programs. In non-Unicode programs, an exception occurs only with deep types, whereas flat types are treated as character-type types.
    Example
    After the assignments,char1 and char2 contain the values "123.456" and "0000123456".
    DATA: pack  TYPE p LENGTH 8 DECIMALS 3 VALUE '123.456',
          char1 TYPE c LENGTH 10,
          char2 TYPE c LENGTH 10.
    MOVE   pack TO char1.
    UNPACK pack TO char2.
    Regards

  • Getting wrong values  for decimal value in Bex report

    Hi,
         I am getting some problem in Bexreport decimal values.
       In ODS i am able to look the values for this key figure
      (Total PO Release Val)= 140.692,00,the same value in Bex report looks like this $ 140,692.00.
         Here one calculation is going with these above values
       % Used = 'Total PO Release Val' / 'Target Value' * 100
        as per ODS value calculation  it is correct = 140.692/1000 * 100 =14.692
       as per Bex  it is coming like this = 140,692.00/1000 *100 = 142.692.
        in Bex report Percentage valus is not considering value is taking as 140,692.00 rather than 140.692.I mean to say decemal values are ignoring while calculation in Bexreport.can you any please advice me how to comeout of this problem.Appreciate your help.
    Regards
    Ramesh

    <i> "(Total PO Release Val)= 140.692,00,the same value in Bex report looks like this $ 140,692.00."
    </i>
    How do you check the ODS value? The amount will only have two decimal places after it, so you can't have a value like 140.692,00. It seems to be an issue of user's decimal notation (where decimal is represented by comma, and thousand seperator by '.'). Go to user profile, change this setting (in default tab) to correct one (ie decimal being represented by '.') and login again and check it. The value that you see in ODS is 'one hundred forty thousand six hundred ninety two, the same that you get in Bex, only the representation is different).

  • Data type for decimal value

    I am making my own database table.which data type shuld I use to display decimal values.I used FLTP but its display is not very clear.
    My values are like1234.56
    Thanks

    assign decimal place while creating domine.
    as per ur req.....
    if it is usefulll.Plz Reward
    Regards
    Anbu

  • Custom thousand separator for decimal values.

    Hello esperts,
    I have a a WD app with a decimal context attribute, I have already a Simple Type that formats the decimal so the thousand separator is a coma (,) and the decimal separator is the dot (.)
    I want to know if it is possible to change the thousand separator to dot and the decimal separator to comma without changing the user's language. Or even use whatever character I want to be the thousand separator e.g. @ | ¬ whithout changing the data type (decimal).
    Thanx in advance.
    JV

    Hi Siarhei,
    I dont want to use calculated fields, nor strings because I need the values of the decimal attribute. I will be desplaying these decimal values through a table and sorting functionality is a must. So as you should know, if I have 1, 2, 3, 20 and 100 and convert them to string, on sort it will be incorrect because of string sorting ( 1, 100, 2, 20 and 3).
    Basically my requirement is to be able to change the decimal presentation without changing the user's locale or language. I don't know if that's possible.
    Say, I select an option on my application that says "comma separated thousands", the decimal values will be presented this way ###,###,###,###.00 or when the user selects the option "dot separated thousands", the decimal values will be presented like this ###.###.###.###,00. I already tried to format the last reprersentation but I get java.lang.IllegalArgumentException: Malformed pattern. I have already checked the DecimalFormat API, so I know the pattern is incorrect, still I'm looking if by chance I'm forgeting something else to do in order the application to work as I spect.
    Thanks!
    JV

  • Sql server max function for decimal value

    dear team
    i have column which contains decimal value eg,
      QuestionMasterId  Studentid   Score
    19                         1            9.01,
    19                         2            9.02,
    19                         3            9.35,
    19                         4            8.04,
     i have to display the max score  - that student score but when i am using the following query it is returning the int value  
      DECLARE @MAX decimal
      SELECT @MAX=max(Score) from [QuestionPaperwiseScore] where QuestionMasterId=19 
      print @MAX
     select Studentid,Score,@MAX-Score as diff from [QuestionPaperwiseScore] where QuestionMasterId=19
    kindly help

    Take a look at
    BOL again. The default scale is 0. Thus it behaves like an INT.
    DECLARE @Sample TABLE
    QuestionMasterId INT ,
    Studentid INT ,
    Score DECIMAL(3, 2)
    INSERT INTO @Sample
    VALUES ( 19, 1, 9.01 ),
    ( 19, 2, 9.02 ),
    ( 19, 3, 9.35 ),
    ( 19, 4, 8.04 );
    DECLARE @MAX DECIMAL(3,2);
    SELECT @MAX = MAX(Score)
    FROM @Sample
    WHERE QuestionMasterId = 19
    SELECT @MAX;
    SELECT Studentid ,
    Score ,
    @MAX - Score AS diff
    FROM @Sample
    WHERE QuestionMasterId = 19

  • Different results for decimal values between SQL and B1 RecordSet

    Hi Experts,
    This is really a strange one. I have the query below:
    SELECT Amount, TaxPrcnt FROM [@Table] WHERE ORDER# = '20246' AND ItemCode = '112488'
    The same query gives me 0.085 for TaxPrcnt if I run it in SQL Management Studio, but gives me 8.5 if I run it in B1 Query Generator, and the same if I use RecordSet object in DI. The actual value in the table is 0.085. Anyone know why B1 is multiplying the value by 100?

    Hi Ronnie,
    sp_prepexec is a system stored procedure used to generate  to prepare and execute a parameterized SQL statement. Have a look at:
    http://jtds.sourceforge.net/apiCursors.html#_sp_prepexec
    Basically, it's another way of passing a query to SQL rather than using a stored procedure. This command shouldn't be converting the data in any way, unless there's a specific cast or calculation in the query itself.
    Can you give simple details of the SQL table you created and I'll see if I can replicate the issue.
    Kind Regards,
    Owen
    P.S. Sorry about the query, I wrote that down this morning before all my brain cells were awake Referencing a field by index only works when grouping and sorting.

  • Data type for decimal values

    Hi experts,
    kindly help me in sorted this..
    in my coding:
    ztest is a structure.
    I want to ask u that what datatype shud i give to my field so that it can gv me acorrect value after appending.
    also i have to sort my data and decimal shud b 2 place only.
    kinldy response
    data: itab like ztest occurs 10 with header line.
    move '0.23566' to itab-value.
    append itab.
    move '1.98323' to itab-value.
    append itab.
    move 900 to itab-value.
    append itab.
    move '100' to itab-value.
    append itab.
    sort itab by value descending.
    loop at itab.
    write: / itab-value.
    endloop.
    thanks n regards
    puneet

    Hi,
    you can declare  the value in the following way.
    DATA : value type p decimals 2.
    Reward points if useful.
    Regards
    rose

  • Public int indexOf(int ch, int fromIdx) doesn't work for some decimal value

    I have tested two strings below. These two string are identical, except the first string has a char 'ƒ, which has a decimal value of 131. And the second string has a char 'À', which has a decimal value of 192. I am expecting the same output, which is 11, but I got -1 for the test I did using the first string. In the API for public int indexOf(int ch, int fromIndex), values of ch is in the range from 0 to 0xFFFF (inclusive). It is highly appreciated if anyone could provide any insights on why -1 returned when the first string is tested. Thank you in advance.
    String strHasDecimal131 = "Test value ƒ, it has a decimal value of 131";
    String strHasDecimal192 = "Test value À, it has a decimal value of 192";
    int badDecimal = 131;
    int idxBadDecimal = strHasDecimal131.indexOf( badDecimal, 0);
    System.out.println( "index of Bad Decimal: " + idxBadDecimal );
    The output is: index of Bad Decimal -1
    int badDecimal = 192;
    int idxBadDecimal = strHasDecimal192.indexOf( badDecimal, 0);
    System.out.println( "index of Bad Decimal: " + idxBadDecimal );
    The output is: index of Bad Decimal: 11

    Thank you everyone for your inputs. Following are the print statements and the output: for character 'ƒ' and ' À':
    System.out.println((int)'\u0083' + ", " + (int)'\u00C0' + " print decimal value" );
    Output: 131, 192 print decimal value
    System.out.println((char)'\u0083' + ", " + (char)'\u00C0' + " print character value" );
    Output: ?, À print character value
    According to Latin-1 Supplement table, the first char in the output would have the appearance of ƒ, instead it has the appearance of ?
    System.out.println( (int)'ƒ' + ", "+ (int)'À' + " print integer value");
    Output: 402, 192 print integer value
    I also have tried to print out the decimal value of following char: € &#65533; ‚ ƒ „ … † ‡, according to Latin-1 Supplement table, these char has decimal value of 128 through 135 and hex value 0x0080 through 0x0087. And the output from java println is: 8364 65533 8218 8222 8230 402 8224 8225.
    System.out.println((int)'€' + " " + (int)'&#65533;' + " " + (int)'‚' + " " +(int)'„' + " " + (int)'…' + " " +(int)'ƒ' + " " + (int)'†' + " " + (int)'‡' );
    As I did before, I print out character of decimal value of 128 through 135
    System.out.println((char)128 + " " + (char)129 + " " + (char)130 + " " +(char)131 + " " + (char)132 + " " +(char)133 + " " + (char)134 + " " + (char)135 );
    Output: ? ? ? ? ? ? ? ?
    Not sure why java prints character for decimal value of 128 through 159 differently from what appears in the Latin-1 Supplement table. Any of your inputs are appreciately.

  • Excel import rounding up decimal values

    In my excel file I have a column that contains dollars and cents (e.g. 49.95). When I run the import the values in this column are rounded up to the next integer (e.g. 49.95 is rounded up to 50). Is this a bug or am I doing something wrong?
    Thanks,
    Peter

    Hi All,
    I have already migrated lakhs of records and I am facing the same problem for decimal value migration. Shall I know whether anyone has fixed this problem? Is there any other free tool for SQL Server to ORACLE migration? Please do guide me as soon as possible.
    Thanks,
    Srinivasan.T

  • Writeback with 'NA'  and decimal values

    Hi All!!!
    We are making some tests on the writeback with the BIBeans; we migrated a db from express to 10gR2 and converted it in
    standard form and we try the writeback on this aw.
    We found some problems when in the worksheet there are one or more 'NA' values to writeback.
    In particular when we call the submitChanges method on the crosstab object (like in the BI sample) if there are one or more
    'NA' values the submitChanges fails and return false.
    We solve this problem implementing the cellSubmitting method and catching the cellSubmittingEvent; in this method we
    substitute the values 'null' for the QDR with an "NA" string.
    We also found that the decimal values (like 180.4) make the writeback to fail; we think it is due to the fact that the
    writeback engine add a '.0' to all the values that we try to writeback so for decimal values we have two character '.'; we
    solve this problem with a support's variable for converting the value to a string and pass it to the set data to the QDR to
    writeback.
    Is this the rigth way?
    Is this a bug?
    Following We report the code we implementing for this method
    public void cellsSubmitting(CellsSubmittingEvent e)
    String app;
    ArrayList qdrCollection = (ArrayList)e.getQDROverrides();
    if (qdrCollection != null)
    int iSize = qdrCollection.size();
    for (int i =0; i < iSize; i++)
    QDRoverride qdrOverride = (QDRoverride)qdrCollection.get(i);
    if(qdrOverride.getData()==null)
    qdrOverride.setData("NA"); //for the problem with 'NA' values
    else
    app=qdrOverride.getData().toString(); //for the problem with decimal values
    qdrOverride.setData(app);
    Hi!
    Daniele De Faveri

    Thanks for your post, it is great solution and it's work for me. I'm supprised that those oversights are still in bibeans and nobody from Oracle havent answered your question.
    Message was edited by:
    Moks

  • Decimal values for EA in MIGO

    Dear Experts
    Recently we have upgraded to SAP AFS 6.5 from SAP AFS 5.0. In previous version we could GR (using MIGO) decimal values for unit of measure EA. Now when we are trying to perform goods receipt decimal values it is automatically rounding off to an integer.
    After go live we got an issue which is similar like this and it was corrected after consulting SAP OSS. check the this; Rounding off in MIGO- Error
    I have checked settings in CUNI in previous and current versions. There is no change. Decimal places are zero. Please suggest if you have any idea on this.
    Regards
    Jeewana

    Hi,
       Please check whether all the correction instructions mentioned in the note:  1971912 
    are implemented correctly. If its already maintained correctly, then you may directly raise an OSS ticket to SAP.
       Also refer the similar notes: 1893043 - Decimal places not allowed in MIGO for movement type 561
    1932640 - Incorrect rounding in asset PO with no material.
    Regards,
    AKPT

  • Inline style - decimal value for dimension break designer

    Hi all.
    I'm using JDeveloper 11.1.2.1 & ADF.
    Just to let you know that decimal value in dimension css selectors (like width...) added using inline style break UI designer.
    af:tree table -> nodeStamp facet -> column -> inlineStyle -> width:305.0px break UI designer.
    Replacing 305.0px with 305px makes everything work Ok.
    .0 part in inline style was added by JDeveloper 11.1.1.5, while JDeveloper 11.1.2.1 doesn't add decimal part.
    Regards.

    Frank, this is i minor issue but it took me 1hour to find what breaks UI designer.
    What I did is just migrated adf application from JDeveloper 11.1.1.5 to 11.1.2.1.
    In JDeveloper 11.1.1.5, when you enter width using property inspector -> style -> layout -> dimension -> width property, let say 305 and select pixel in side drop down list, what you get as result is inlineStyle property like this:
    inlineStyle="width:305.0px"
    Frank Nimphius wrote:How would 305.2 pixel look like ?You should ask Oracle to answer this question.
    Thank you for your reply.

  • Any std funtion(s) for Zero-padded, 2 decimal value, without the deci point

    Hi,
    We want Zero-padded, two decimal value, without the decimal point. For example if it is 14.31, we need 001431.
    I have done "multiply" with 100 and "formatNumber" as '000000'
    SFIeld --> multiply * 100 --> formatNumber (000000) --> TField
    It works good for values with decimal like above 14.31, does it work for everything else too? I mean for 12 it is populating as 001200. Is this best approach? Is there any other std funtions or UDF sample available?
    Regards,
    N@v!n

    >
    N@v!n Kumar wrote:
    > Hi,
    >
    > We want Zero-padded, two decimal value, without the decimal point. For example if it is 14.31, we need 001431.
    > I have done "multiply" with 100 and "formatNumber" as '000000'
    >
    > SFIeld --> multiply * 100 --> formatNumber (000000) --> TField
    >
    > It works good for values with decimal like above 14.31, does it work for everything else too? I mean for 12 it is populating as 001200. Is this best approach? Is there any other std funtions or UDF sample available?
    >
    > Regards,
    > N@v!n
    public void convert_number(String[] FieldValue,ResultList result,Container container){
    FieldValue = FieldValue * 100;
    result.addValue(FieldValue);

Maybe you are looking for

  • AP - Invoice Discounting Issue

    Hi, I'm troubleshooting an issue where invoices that are not meant to have discounts, are having a First Discount amount applied. This discounted amount is then paid in a payment run, when the full amount should be paid. The invoice terms are 2% 3 Da

  • Using REPLACE with IN clause

    Hello, I'm using 9.2.0.5.0 production and 9.2.0.7.0 development. I have a string such as: '4388:4410:4411:4412:4413:4414:4415:4416' I need to use this string in a SQL statement (not PL/SQL) such as: SELECT originalcalledpartynumber Agent, count(1) "#

  • Trouble unzipping files

    I'm trying to open files with .mxd, .mdb, .xml and .ldb extensions. When I do so, an error message prompts me to choose a default application to open them. I would have thought that choosing Stuffit Expander would do the trick, but that doesn't work.

  • Installed HTML DB, how to login to HTML DB

    Stupid question may be, but I am only able to see the Start and Stop HTTP Server options after successfully installing the HTML DB on the existing 10g oracle db in my PC. I am able to go to the welcome page (url given at the end of installation). Whe

  • What's with the occasional "Unsupported image format" errors?

    I get this error randomly -- suddenly Aperture can't show me anything but a brief flash of the image, and then I get the maroon screen "Unsupported image format" error. Restarting Aperture returns things to normal. I've seen this in both version 1.5.