LSMW field with 5 decimal points

Hi All,
I need to pass a field in the LSMW with 5 decimal points.
we cannot pass the data type as "PAC5". can any one suggest how this can be done in LSMW.
Also, I am passing the currency key as USDN in the LSMW using Idoc method. But it is taking only as USD even though the length of the field is 5 chars. But I am able to acheive this if I manually post it as USDN.
please suggest on the above 2 issues.
Helpful answers will definitely be rewarded.
Thanks in Advance,
Asif Ali Khan

hi khan,
see the below link
http://www.abapcode.sapbrainsonline.com/2008/03/write-output-formatting-options-abap.html
http://www.abapcode.sapbrainsonline.com/2008/03/types-abap-keyword.html
sapabap.iespana.es/manuales/pdf/lsmw.pdf
abapprogramming.blogspot.com/2008/03/sap-abap-syntax-for-assign.html - 122k
abapprogramming.blogspot.com/2008/03/sap-abap-syntax-for-assign.html - 122k
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/90cef248-29e0-2910-11bb-df8dece7e22c
thanks
karthik

Similar Messages

  • Working With Prices/Decimal Points

    I've recently figured out how to perform calculations on values by assigning them to variables in a click function however I'm working with prices in my app and it seems difficult to get prices/decimal points to claculate properly. At the moment my app looks like this:-
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application
    xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical">
    <mx:Script>
    <![CDATA[
    private function getTotal():void{
    var addon1Int:int = parseInt(addon1.text);
    var addon1Float:Number = parseFloat(addon1.text);
    var addon1Number:Number = new Number(addon1.text);
    var addon2Int:int = parseInt(addon2.text);
    var addon2Float:Number = parseFloat(addon2.text);
    var addon2Number:Number = new Number(addon2.text);
    var addon3Int:int = parseInt(addon3.text);
    var addon3Float:Number = parseFloat(addon3.text);
    var addon3Number:Number = new Number(addon3.text);
    var addon4Int:int = parseInt(addon4.text);
    var addon4Float:Number = parseFloat(addon4.text);
    var addon4Number:Number = new Number(addon4.text);
    var addon5Int:int = parseInt(addon5.text);
    var addon5Float:Number = parseFloat(addon5.text);
    var addon5Number:Number = new Number(addon5.text);
    var quantityNumber:Number = new Number(quantity.value);
    total.data = (addon1Number + addon2Number + addon3Number + addon4Number + addon5Number) * (quantityNumber);
    ]]>
    </mx:Script>
    <mx:Text id="addon1" text="5.99"/>
    <mx:Text id="addon2" text="6.99"/>
    <mx:Text id="addon3" text="8.99"/>
    <mx:Text id="addon4" text="4.99"/>
    <mx:Text id="addon5" text="3.99"/>
    <mx:NumericStepper id="quantity"/>
    <mx:Button label="Button" click="getTotal();"/>
    <mx:Text id="total"/>
    </mx:Application>
    It works ok if the numbers in the text areas are whole numbers like 8 or 4 but if I use numbers like 02.99, 05.09 the result comes out a bit srange. For example the result of the numbers that I have in there now if I set the value to 2 in the numeric stepper is 61.900000000000006 when I know from using a real calculator it should be 61.9. Is there any way perhaps of rounding this code to the nearest decimal point so it appears as 61.90?
    Are there any good tutorials that any of you know of when working with prices/decimal points in flex?

    I've managed to find the solution for this - the currency formatter. If anyone's interested or has similar problems her's the code that solves it for me:-
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application
    xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical">
    <mx:Script>
    <![CDATA[
    import mx.formatters.NumberBaseRoundType;
    private function getTotal():void{
    var addon1Int:int = parseInt(addon1.text);
    var addon1Float:Number = parseFloat(addon1.text);
    var addon1Number:Number = new Number(addon1.text);
    var addon2Int:int = parseInt(addon2.text);
    var addon2Float:Number = parseFloat(addon2.text);
    var addon2Number:Number = new Number(addon2.text);
    var addon3Int:int = parseInt(addon3.text);
    var addon3Float:Number = parseFloat(addon3.text);
    var addon3Number:Number = new Number(addon3.text);
    var addon4Int:int = parseInt(addon4.text);
    var addon4Float:Number = parseFloat(addon4.text);
    var addon4Number:Number = new Number(addon4.text);
    var addon5Int:int = parseInt(addon5.text);
    var addon5Float:Number = parseFloat(addon5.text);
    var addon5Number:Number = new Number(addon5.text);
    var quantityNumber:Number = new Number(quantity.value);
    var total:Number = (addon1Number + addon2Number + addon3Number + addon4Number + addon5Number) * (quantityNumber);
    totalAmount.text=currencyFormatter.format(total);
    ]]>
    </mx:Script>
    <mx:CurrencyFormatter id="currencyFormatter" precision="2" rounding="none" decimalSeparatorTo="." thousandsSeparatorTo="," useThousandsSeparator="true" useNegativeSign="true" currencySymbol="£" alignSymbol="left"/>
    <mx:TextInput id="addon1" text="5.99"/>
    <mx:TextInput id="addon2" text="06.99"/>
    <mx:TextInput id="addon3" text="08.99"/>
    <mx:TextInput id="addon4" text="04.99"/>
    <mx:TextInput id="addon5" text="03.99"/>
    <mx:NumericStepper id="quantity"/>
    <mx:Button label="Button" click="getTotal();"/>
    <mx:Text id="totalAmount"/>
    </mx:Application>

  • South America localization with comma decimal points

    Hello All:
        I am doing a simple division on a formatted search. However it is south america localization and it has the comma as decimal point instead of period. If I just do value 1 / value 2 it give me error message. if I replace , and then cast to numeric and then divide it works. But put in a trigger by formatted search it comes out as a wrong monetary value. The UDF for the FS is a quantity value. Not monetary!
        How does anyone do normal division and multiple with South America localization?
        Thank you for all the help!

    The field itself is actually a UDF of type Quantity. So using the quantity select $[$38.11.0]/$[rdr1.U_myfield]
    I suppose for checks you can just divide quantity by price or something! But it doesn't seems  to work for me!

  • My quantity is showing with a decimal point and two spaces

    When people are entering a quantity of 1 it is showing as 1.00.  It is confusing my users because they think this is a price.  How can I get rid of the decimal point and two spaces? 

    Hi,
    I am not able to reproduce this problem with a number field.  Are you using this field as a payment-quantity field?.  If so, please check that the Quantity in your payment setting is linked the the right field.
    We can do a quick test: create a new form from scratch, add one textfield, then on the field property panel select Type=number.
    Select Test tab and click on the Test Web Form button
    Enter a number and commit --> check if you get the decimal point and the spaces.
    If you still have problem with this, let me know
    Thanks,
    Lucia

  • Display unsigned value (battery voltage) = 8134 formatted with a decimal point: 8.134

    How can I display an unsigned value such as 8134 with an "implied" decimal point e.g. 8.134 without dividing by 1000? Is there a format code that will do this? I have Student Version 8.2.1. Many thanks

    It seems silly to force such an arbitrary restriction. A division is cheap, why son't you want to do it???
    Of course you could assign a unit such as V and then set the units to kV for the display.
    I would go with the division!
    Message Edited by altenbach on 11-18-2007 04:58 PM
    LabVIEW Champion . Do more with less code and in less time .
    Attachments:
    DivideBy10.png ‏5 KB

  • EBAN-PREIS field removes the decimal point and add the zeros to the value

    Hello,
    Could you please let me know if you have seen a behavior like this where a currency field has issues with the decimals when the currency is JPY or VND. In my case the field EBAN-PREIS saves the data incorrectly. For example the correct value is 1000 and when you checked EBAN it changes to 100,000.
    Let me know your thoughts about why this could be happening.
    Thanks!
    Roy

    Please check if there is any routine or user exit which is converting as per business requirement.
    Because even i too had faced the same problem when updating the Excise details. but later on found out that some one has written exit for calculating on the basis of units conversion.
    Regards,
    Chandrasekhar Bade

  • Reports with 2 decimal points

    Dear Experts
               I want to increase the decimal places of INR from 2 Decimal places to 6 Decimal places,But i want the standard SAP reports to come in 2 decimal places for INR even after changing to 6 decimal places.please Give me solution to this request..

    Hi,
                        Actually what others said is right,but u can use the formula round and round it off to Two digits.
    Example: Field name F_012
    Insert a new field -->select source type -->Formula
    and in the empty space Round(F_012,2)......It will give the cost or rate in two decimal places.
    But u have to do this in every report.
    Regards,
    Shyam

  • Font size with a decimal point

    I've been making a Safety Manual for a company that I am working for and for the past month everything has been going smoothly, for the most part. That is until today. As usual I am changing my font size and it all of the sudden won't let me change the size,
    I put my cursur there and it is black and makes a beep (the beep that means you are doing something wrong). Please help me, as I'm on my last 3 pages.
    Thanks,
    Chantal

    Hi,
    Was the decimal number created by yourself? If not, please try to paste the number in notepad first, then copy paste the numbers to your document.
    You mentioned, everything was fine till today. Was there any changes in your OS or office?
    Also do you mind to share me a copy (keep just the decimal part which you can’t change font size) to:
    [email protected]? So I can test it from my side. Please use thread link or the subject of this post as mail subject.
    Thank you.

  • PDF Forms: problem with keypad "decimal dot" when filling "number" fields

    Ok, here's my problem :
    I've created a form with fields. My client want to input in those fields amount of money. So I've created fields formatted with the "Number" category. 2 decimals, "1234,56" separator style, not currency symbol. So far, so good!
    When testing out the form, here's what happening :
    On the computer that I've created the form (iMac, Acrobat Pro and Reader, french canadian keyboard layout and system)
    Using the keypad, I can input numbers, with the "decimal point" from the keypad no problem.
    But when the client is trying to to the same on his PC (and the same is happening with my PC at home, Acrobat Pro 9.2, french canadian keyboard layout and system), I CAN'T use the "decimal point" keypad key to input numbers (like 43,25). It's just not working (error sound). I can however use the "dot" on the keyboard near the "M" key, but the client don't want to do that.
    Why is it working on the Mac, but not on the PC's!?
    So far, the only workaround that I've found is to set the "money" fields categories to "none" instead of "number.

    It is a little bit tricky, but you might have to add your own formatting handler. You would proceed as follows:
    1. Set the Format to "none".
    2. Add the following script to a Custom Keystroke event:
    if (event.change.length > 0 && event.willCommit == false) {event.change = event.change.replace(/\,/gim, ".") ;
    3. Add the following script to a Custom Format event:
    event.value = event.value.toString().replace(/\./gim, ",") ;
    And that should take care of the situation.
    Note that i have not tested the scripts, and there may be a chance for bugs.
    The advantage of this solution is that internally, you will have the correct format for a number, so that calculations will be correct.
    Hope this can help.
    Max Wyss.

  • How do I enter data in excel with a specified number of decimal points?

    I have several inputs that are being written into excel using the "Write to Spreadsheet file" vi. One of my inputs only writes to excel with 3 decimal points. I would like it to have four, how do I change this?

    Pop-up on the top input to the "Write to Spead...." labled "Format".
    Chnage it from the default of "%.3f" to "%.4f"
    Ben
    Ben Rayner
    Certified LabVIEW Developer
    www.DSAutomation.com
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • Problems with Illustrator CS6 not accepting stroke weights with decimal points

    So I have been using Illustrator for almost 10 years and have never run into this one. When enter a stroke weight on a line with a decimal point like .25 or 4.5 is keeps rounding the number up. For example I enter 0.75 and it makes it 1 point or I enter 5.5 and it makes it 6 point. Whether I enter the number manually or pick from the drop down (0.25, 0.5 or 0.75) it keeps rounding my strokes to even numbers. How did I do and how do I fix it?

    Thanks from me too! Was also very frustrated by this.

  • Currency Decimal Points - Urgent

    Hi,
    I am facing a serious problem with currency decimal points. Unfortunately "Currency code" has been deleted from where we can maintain currency decimal points in OY04 Tcode and the currency code was maintained by zero decimal places. Before deleting the Currency from decimal points the document currency was showing $1000.00 which is correct. But after deleting Currency Code from OY04 Tcode the same amount is showing $100000 by combining decimals.
    I have again given same Currency Code in same transaction code. But still it is showing ($100000) the amount by combing the decimals.
    Please help me
    Thanks
    Ravindra

    You said someone "unfortunately" deleted an entry from table TCURX.  Has that someone seen all the following WARNINGS given by SAP!!!
    In a productive system, you must not delete the currencies in use or change the decimal places.  This could make amounts in documents already posted incorrect or invalid.
    Before you continue, please read the following text carefully.  If you do not heed this note, you can cause irreparable damage to the system with this transacton.  In the R/3 System tables currency fields are stored as decimal figures with a variable number of decimal places. The decimal point is not stored in the field in the database. Instead, each currency field refers to a currency key field. In this transaction you assign the number of decimal places to this currency key uniquely.  Example: If you have set currency USD to have two decimal places and you post an amount of 100 USD, an amount of 10000 USD is stored in the currency field in the database. Not until this amount is processed further or is output does the system use the currency key from the reference field to determine the number of decimal places via this table. In this way the table content can be interpreted correctly for further processing or formatted for output with the correct punctuation.  If after posting you changed the number of decimal places for USD, for example, to 3, the existing field content of 10000 would be interpreted for futher processing or output as 10 USD (10.000). This would mean that the contents of tables across the system would, for all currency fields containing an amount in USD, be interpreted incorrectly by 10 per cent. To        
    change the number of decimal places for a currency already in use, you must convert all the tables in the R/3 System that contain
    currency fields, so that the data integrity remains. This cannot, however, for both organizational reasons and under the runtime aspect be carried out in a productive system.  The following changes to the TCURX table can thus lead to the loss of data integrity if you        
    make the changes in a productive system or transport them into a productive system:
    o Change to the number of decimal places of an existing currency                                   
    o Deletion of an entry from the TCURX table (corresponds to changing the decimal places to the standard value of two decimal places)           
    o Insertion of an entry in the TCURX (corresponds to changing the standard value of 2 decimal places to a different value), if this is a currency code that already exists Uncritical changes are any made to this table during the Customizing of a new installation or the insertion of TCURX even during operations, if the currency codes have just been entered in the TCURC table using transaction OY03, signifying that no postings to these currency codes can have been carried out yet.
    Do you want to change the decimal places despite all recommendations?

  • Reg: Quantity field taking as decimal values

    Dear Experts
    In the Bapi BAPI_SALESORDER_SIMULATE the structure BAPIITEMIN contains a field Req_qty that has the data element WMENGC which is taking the input with 3 decimal points even though the domain doesnt contains any decimals, because of this im facing the problem while giving the input.
    Is there any functional requirement to avoid that quantity field taking those 3 decimals
    eg: Original Value: 1000
          Input Value(Converted Value)    : 1.000
    Kindly suggest me a solution to sort out the issue.
    Regards
    Arun.P

    well i suspect that this bapi also has a currency field, which you should fill.
    If he knows the currency he should be able to find out how much decimals there are customized for this currency, and then probably he will do it right.
    oh lol you are talking of quantities and not values... sorry forget about my comment...
    Edited by: Florian Kemmer on Jul 22, 2010 2:37 PM

  • Loading Implied Decimal Points

    I have some text data that contains numbers with IMPLIED decimal points. I would like the location of the decimal point to be reflected in the loaded data. My numeric text data is fixed width character with the numeric sign as the first character of the field. Using ZONED(12,3) does not pick up the 3 decimal places. Can Oracle do this? Any help is appreciated.
    Chet

    Hi,
    Go to IMG - Public Sector Management - Funds Management Government - Budget Control System (BCS) - Budget Entry - Budget Entry Documents - Specify Editing Options for Budget Amounts.
    Please, notice that the default number of decimals corresponds to the FM area currency you have set in customizing.
    Regards,
    Eli

  • Decimal points not displayed correctly

    Hi team,
    I am experiencing issues with displaying decimal points in the following fashion (selected element spinner and changing the number format in the appearance tab):
    Number Format: Percent
    Decimal Points: 0
    50%
    Number Format: Percent
    Decimal Points: 1
    50%
    Number Format: Percent
    Decimal Points: 2
    050%
    Number Format: Percent
    Decimal Points: 3
    0.050%
    Number Format: Percent
    Decimal Points: 4
    00.50%
    I was expecting something like this:
    Number Format: Percent
    Decimal Points: 0
    50%
    Number Format: Percent
    Decimal Points: 1
    50.0%
    Number Format: Percent
    Decimal Points: 2
    50.01%
    Number Format: Percent
    Decimal Points: 3
    50.012%
    Any views?
    Many thanks,
    Frank

    Amit/Frank,
    This is stange...
    Spinner is working differently in different systems...:) I tried it on 3 different systems...
    One system shows..
    Value is 50
    Number Format: Percent
    Decimal Points: 1
    5000.0%
    Number Format: Percent
    Decimal Points: 2
    5000.00%
    Second system...
    Value is 50
    Number Format: Percent
    Decimal Points: 1
    50%
    Number Format: Percent
    Decimal Points: 2
    050%
    and 3rd system..does not show up any change be it Decimal Points 1 or 2, it still shows 50
    -Anil

Maybe you are looking for