Checking amount sum in file body

helo all
here i got problem with my scenario.
in my scneario iam  processing file to bapi.
before processing i need to check the amount present in file body and to compare with trailer sum if both r same then i need to set flag of bapi to yes otherwise it should be no.
but while iam checking the decimal amount values in body its chowing some difference.
i got the sample file anf i checked the sum it should be 5043.4 but the sum (statistic function) was shown like 5043.444 but when i sum it manually its fine.
so what i have to do to solve this issue.
waiting for u r response.
bye.
regards.
seeta ram.

seeta ram
Now, dont you see the same set of solutions re-appearing?
If it didnt solve the problem, why dont you use the same thread . It would save the time of other SDNers and also will help you get closer to where you would like to get.
regards
krishna
P.S The fix has already been pointed out. Only you have to implement the fix and make it work. We are here to help you if your are facing any problems while applying the fix but if you don't go anywhere close to applying the fix, it would be hard for us to help you in this regard.
Message was edited by:
        Krishnamoorthy Ramakrishnan

Similar Messages

  • Trouble trying to get correct AP Check Amount total on a report

    Okay, the challenge is to try and explain my situation well. I am in Discoverer Plus. I am working to develop a Discoverer report that will show, for accounts payable application, a summary report by bank name and job number, a check count, invoice count, and check amount total. For simplicity sake, since I have the problem once I go past one table, I am dealilng with tables ap_checks_all and ap_invoice_payments_all from EBS, the tables joined on check id. Now, if I work just with the ap_checks_all table, I can easily get the correct sum of check amounts (column name in the table is AMOUNT). However when I bring in the invoice payments table, then I run into trouble. I first did the SUM data point for AMOUNT, and got a number that was way too high. Figured out that is because anytime I have multiple invoices on a check (which is most of the time), the check amount gets added in for each invoice. So if check amount is $100.00 and the check pays 5 invoices, $500.00 is added to the total amount, instead of the just the $100.00.
    So I tried the SUM_DISTINCT function next - SUM_DISTINCT(AMOUNT). Got me a lot closer, but now my total was too low. Figured out that was because if I had separate checks with the same check amount, that check amount only gets added in one time. Say Check 18 is for $100.00 and Check 39 is for $100.00, I only get $100.00 into the total instead of $200.00. Which when you think about it, is exactly what the SUM_DISTINCT function means. Since the chances of check amounts being duplicated are low, that is why I get close to the right number, but when dealing with tens of thousands of checks, check amount duplication does happen.
    So on my totals for the SUM_DISTINCT column, I finally figured out that a CELL SUM got me closer to the right number. I only had a problem now when, on the same bank name and job number, would still have duplicate check amounts at that key (group by) status level. Percentage wise, my error is low - off maybe $200,000 out of $180,000,000. So close to the right number, yet so far.
    The same thing happens in raw SQL. If you think about the raw join result, you can see what is happening -
    check 1, check 1 amount, invoice 1
    check 1, check 1 amount, invoice 2
    check 2, check 2 amount, invoice 3
    check 3, check 3 amount, invoice 4
    So if you do SUM(CHECK AMOUNT), well yeah, it will add in the check 1 amount twice.
    If you do SUM_DISTINCT(CHECK AMOUNT), then check 1 amount only gets counted once. Great. Ahh, but what if check 3 amount = check 1 amount? Oops, the check 3 amount is excluded.
    Does anyone know of a way to get around this problem? I have been playing around with the functions, but the SQL reference does not give many examples to help understand all the various optional parameters. I know, in vague concept, what I want. Something like -
    SUM(AMOUNT) DISTINCT ON CHECK_ID, or
    SUM_DISTINCT(AMOUNT) DISTINCT ON CHECK_ID.
    CHECK_ID is the internal Oracle id number for each check, from the ap_checks_all table. Check number is not unique enough, since different bank accounts may be using the same check number in the same time period. So I want a way to be able to add my check amount to the total one time when there are multiple invoices on the check, and then get each invidual check amount (one time) added up to get my check total amount.
    Like I said, no problems with Discoverer or raw SQL if doing just one table. But once I join checks to invoice payments, poof, I run into trouble.
    I did not think I was trying to do anything unusual. So quite surprising that having so much trouble trying to find a way around this problem.
    Hope this detail explanation makes some sense. Thanks for any help/insight anyone can give me.
    John Dickey

    Michael,
    Nope, that does not work. It truly just gives me an average. My desired (table) report row format is this -
    Bank name , Job Number, Check Count , Invoice Count , Check Amount Total
    So this is a SUMMARY report. Not a detail report. If I do detail, I do not have any problems - I get my correct check amount total. If I do just the ap_checks_all table, I get the correct amount (but then cannot get my invoice count). I get the correct check count (count distinct on check id). I get the correct invoice count. When I added a calculation column using the Average function as you suggested, I see on each row what is likely the average check amount. Which is exactly what you would expect to see.
    Now I did get a brainstorm and tried this. I calculated both the average and average distinct on check amount, then multiplied each by my check count. Darn. Still does not work. The Average Distinct * Check Count = SUM_DISTINCT(CHECK AMOUNT), which I already have. Average Distinct apparently only includes a duplicate check amount one time in calculating the average (which when you think about it, makes sense, darn it). The AVERAGE function still has the problem, it looks like, of including the check amount each time on checks with multiple invoices (and thus multiple rows in the join result) in determining the average. Which when you think about the raw join result from joining checks to invoice payments tables, makes sense. The result of AVERAGE * CHECK COUNT is better than the SUM(AMOUNT) column, but not as good as the SUM_DISTINCT(AMOUNT) column.
    Any other ideas? Interesting that something that seems like a pretty basic thing to do, if it does have a solution, is not a very obvious/simple solution.
    John Dickey

  • Negative amount in IR8A File

    Hi,
    Why do I get negative amount in IR8A file specifically in benefits in kind balances(MOA 275 & MOA 351)? How do I fix them?
    Thanks,
    Jerico

    Thanks harish for ur inputs.
    OMPP
    SMPN
    SMPR
    OMPP,SMPN,SMPR wagetypes are knowcking off (sum of smpn+smpr is entered as -ve OMPP) or ofsetted for past periods like jan,feb months ..for march it is not the case and in april  month there is XXXX wagetype as SMP Payment Adjust (NEW) which has -ve value.can it be used as norm?
    have ur come across similar issue in the past ?pl let me know if there is a work around...
    thanks for ur help.
    no worries,karthik

  • Void check - amount and issue date

    We do FCHX check extract to send the positive pay files to Bank. With FCHX, the issue date and amount is not getting extracted for voided checks. How can we populate these values (issue date and amount) in the file extract (FCHX) for check
    The data in the file is sorted according to account number and check number and its format corresponds to the internal format of the DTACHKH and DTACHKP structures.
    Thanks
    Ron
    Edited by: Ron on Mar 10, 2010 1:53 AM

    Hi,
    We can void a issued check and also unissued check.
    For unissued check, there will not be any amount and issue date. So no porbs.
    For the the issued scenario, bank just need infomration about the voided check number only, irrespective of amounts and issue date as per the standard practise is concerned.
    May be this information will not be useful to you...just to confirm...
    Thanks,
    Srinu

  • How to check if a specific file exist and which exit code to use ?

    Hi, First I'm not a scripting guy and I know almost nothing about VB scripting.
    I have a deployment of 6 tasks and I want to make sure that step # 2 will not be process if it failed in step #1, and so on for the 6 task.
    To do this, i have to run a vb script before installation or uninstalltion on each steps
    I'm trying to use a script (not from me) that i have modified for pre-uninstallation of software and also post-installation of the software.
    Pre-uninstallation: The script will look if the specified "exe" exist on the server and if so, than it will run the msiuninstall "application_name".
    If the uninstallation is successful, the post-installation script will check if the "exe" file exist again on the server, and it shouldn't find it (because it was deleted from the uninstallation), than it will return an exit code of successful
    to run the next process.
    Here an example:
    Step 1: Uninstall "Software#1" with msiuninstall Software#1.exe command
    Step 2: Uninstall "Software#2" with msiuninstall Software#2.exe command
    Step 3: Install "Software #3"with an .exe extension
    Step 4: Re install "Software #2" with an .msi extension
    Step 5: Re install "Software #1" with a .msi extension.
    Step 6: Send email to confirm the deployment is successful
    So i need to validate that step #2 will not process step #3 if it failled on # 2. It need to validate if the file exist before and after.
    At the end, Step 6 should send an email to confirm that the 6 steps of the deployment was completed without errors.
    Any idea how to do it ?
    Many many thanks for all the help !
    A desperate guy :)
    This is what i have
    'This script will look if an .exe file exist for a specific application.
    '=============================================================================================
    path = WScript.Arguments.Item(0)
    set objFSO = CreateObject("Scripting.FileSystemObject")
    If objFSO.FileExists(C:\Inetpub\wwwroot\Enterprise\EnterpriseWS\web.config) = true then
        exitCode = 0
    else
        exitCode = 1
    End If
    Wscript.Quit exitCode

    Since you are not a scripting guy here is a very good place to start:
    http://technet.microsoft.com/en-us/scriptcenter/dd793612.aspx
    ¯\_(ツ)_/¯

  • I am using Outlook 2010 and have a iphone 4s.  In Outlook I have issues with my contacts not being the same as what I have corrected them to be.  Is there a way to check and see which file Outlook is sharing with I-cloud?

    I am using Outlook 2010 and I also use a Iphone 4s. I use Outlook to correct all my contacts and them it sync with my phone BUT I get different variations of the contacts.  Almost as if there is another file it is going to.  Can I check to see which file it is reading from??

    This may be helpful.
    http://itconflict.com/2012/01/08/troubleshooting-icloud-sync-with-outlook/

  • Post install checks failed for DBC file - Oracle App11.5.10.2 Linux  5.3

    Hi everybody,
    I tried Installing Oracle E-Business Suite 11.5.10.2 on Red Hat Enterprise Linux Server release 5.3
    The Post install checks failed for DBC file, HTTP, JSP and PHP. Apparently the DBC hadn’t been created. I had verified the log file, while executing adgendbc.sh, it throwing below error.
    Generating /jith/d01/oracle/appl/visappl/fnd/11.5.0/secure/prithvi.bangalore.bedford.local_vis.dbc
    DBC generation failed with exit code 127
    Generating /jith/d01/oracle/appl/visappl/fnd/11.5.0/secure/prithvi_vis.dbc
    DBC generation failed with exit code 127
    Updating Server Security Authentication
    Updating Server Security Authentication failed with exit code 127
    adgendbc.sh exiting with status 127
    ERRORCODE = 127 ERRORCODE_END
    .end std out.
    touch: error while loading shared libraries: librt.so.1: cannot open shared object file: No such file or directory
    sqlplus: error while loading shared libraries: libdl.so.2: cannot open shared object file: No such file or directory
    mkdir: error while loading shared libraries: libc.so.6: cannot open shared object file: No such file or directory
    grep: error while loading shared libraries: libc.so.6: cannot open shared object file: No such file or directory
    sed: error while loading shared libraries: libc.so.6: cannot open shared object file: No such file or directory
    /jith/d01/oracle/appl/viscomn/util/java/1.4/j2sdk1.4.2_04/bin/java: error while loading shared libraries: libpthread.so.0: cannot open shared object file: No such file or directory
    cp: error while loading shared libraries: libc.so.6: cannot open shared object file: No such file or directory
    /jith/d01/oracle/appl/viscomn/util/java/1.4/j2sdk1.4.2_04/bin/java: error while loading shared libraries: libpthread.so.0: cannot open shared object file: No such file or directory
    cp: error while loading shared libraries: libc.so.6: cannot open shared object file: No such file or directory
    /jith/d01/oracle/appl/viscomn/util/java/1.4/j2sdk1.4.2_04/bin/java: error while loading shared libraries: libpthread.so.0: cannot open shared object file: No such file or directory
    cp: error while loading shared libraries: libc.so.6: cannot open shared object file: No such file or directory
    /jith/d01/oracle/appl/viscomn/util/java/1.4/j2sdk1.4.2_04/bin/java: error while loading shared libraries: libpthread.so.0: cannot open shared object file: No such file or directory
    /jith/d01/oracle/appl/viscomn/util/java/1.4/j2sdk1.4.2_04/bin/java: error while loading shared libraries: libpthread.so.0: cannot open shared object file: No such file or directory
    .end err out.
    Thanks in advance.
    sreejith

    Welcome to the forums !
    Pl post EBS related question in the EBS forums at http://forums.oracle.com/forums/category.jspa?categoryID=3
    HTH
    Srini

  • Function module to check if a given file/folder path is valid or not?

    Hi,
    I am using function modules GUI_DOWNLOAD and GUI_UPLOAD.
    Is there any function module to check if a given file/folder path is valid or not?
    Thanks.

    Hi Kumar ,
    REPORT  zdir_test.
    TYPE-POOLS: abap.
    DATA: v_dir TYPE string.
    DATA: v_bol TYPE abap_bool.
    v_dir = 'c:\sap\'.
    CALL METHOD cl_gui_frontend_services=>directory_exist
      EXPORTING
        directory            = v_dir
      RECEIVING
        result               = v_bol
      EXCEPTIONS
        cntl_error           = 1
        error_no_gui         = 2
        wrong_parameter      = 3
        not_supported_by_gui = 4
        OTHERS               = 5.IF NOT v_bol IS INITIAL.
      WRITE:/ 'Directory exists.'.
    ELSE.
      WRITE:/ 'Directory does not exist.'.
    ENDIF.
    Regards,
    Sachin M M

  • I keep getting the message: "what should firefox do with this file" in Windows XP every time I want to download a file, e.g., adobe, excel, etc. How can this annoying message be deleted? The check box to "open file automatically" does not work!

    I keep getting the message: "what should Firefox do with this file" in Windows XP every time I want to download a file, e.g., adobe, excel, etc. How can this annoying message be deleted? The check box to "open file automatically" does not work!

    cor-el,
    Thanks for your prompt reply. However, the sources you gave do not seem to apply exactly to my situation. I have attached some screenshots that show what the dialogue box looks like for a pdf download, and what my settings in the Apps panel of Options are. You will note in the first screenshot that I have checked the box to handle this file type automatically; however, the next time I try to download a file of that type, the same dialogue box appears looking exactly like the one shown, so checking the "automatic" option appears to do nothing. The files to be downloaded from my Gmail messages are not generic or altered file types - they are shown as pdf, doc, docx, etc. So while your intent was good, your post did not help. Thanks anyway.

  • How do i delete a large amount of locked files at one time?

    How do i delete a large amount of locked files at one time or batch unlock the files to delete them?

    Drag them to the Trash and hold your Option key down when selecting Empty Trash.   
    17" 2.2GHz i7 Quad-Core MacBook Pro  8G RAM  750G HD + OCZ Vertex 3 SSD Boot HD 
    Got problems with your Apple iDevice-like iPhone, iPad or iPod touch? Try Troubleshooting 101

  • XI30 File Adapter - check for (NOT) incoming file

    Hi!
    We use XI30 SPS15 and have the following challenge: We expect every
    week on a certain day a file coming from a customer. So far so good.
    But now we want to check whether such a file has really come within a
    given period of time and if not, we want to take some action (e.g.
    trigger Alert or s.th. like that).
    Business Background is: If the customer does not send the file or he
    sends it too late, we cannot bill him in time, thus increasing our DSO.
    Is there any mechanism within the XI to check things like these and to
    trigger an alert? I've read the File Adapter Documentation as well as
    the BPM documentation but I could not find any hint.
    Any help would be great. Thanx!
    Regards,
    Volker kolberg

    hi volker,
    this is not supported in standard but...
    you can do it very easily with standard ABAP job scheduling
    - you schedule a job (every week, day etc.)
    which starts a raport that send a RFC (or abap proxy call to the XI)
    - then the RFC starts a BPM and inside it triggers a
    java proxy that checks for a file
    - if the proxy finds the file then if copies it to some other folder (which is monitored by another flow)
    - if it doesn't find the file it triggers an error - sends mail or anything
    the only thing you need to code is a few lines in java
    to check the existance of a file + copying nothing else:)
    this is the easiest way I believe till now <= Sp15
    Regards,
    michal
    <a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions">XI FAQ - Frequently Asked Questions</a>

  • How to check for a compressed file

    hi,
    I need to restrict the user to upload only compressed files (zip,sit etc.).
    how do u check whether the input file is compressed or not. is there any way to do that? or should i check only with the extension?
    Thanuja.

    Checking the extension is the best what you can do. You can also consider the java.util.zip API [1] to check if the file is decompressable, but that is rather expensive.
    [1] http://java.sun.com/j2se/1.5.0/docs/api/java/util/zip/package-summary.html

  • I did a backup from all my files saved in old external hd to time capsule. After that double checked and recover one file from TC to mac air and it worked just perfect. Today went through TC to recover another file and none of them were there?

    I did a backup from all my files saved in old external hd to time capsule. After that double checked and recover one file from TC to mac air and it worked just perfect. Today went through TC to recover another file and none of them were there?Anybody has a clue what happened?

    renatocremonese wrote:
    I want to use it for backing up my Mac.
    It's good for that . . . 
    But also I don't keep all my stuff in my Mac.
    But not for that. 
    This older and not day-by-day usage files I want to store in the time machine.
    You can do that (see below), but how are you going to back them up?   If your only copies are on the TC, when (not if) it fails, you risk losing your only copy of the data.
    Is it possible to split TC in two partitions.
    No, but there are some workarounds, including making a fixed-size disk image on it to "reserve" some space.  See #Q3 in Using Time Machine with a Time Capsule.
    But you still won't have backups of the stuff you put there.
    You don't say what kind of Mac you have.  If it's a desktop model, just keep the external HD connected to it, and let Time Machine back it up along with your internal HD.
    However, it sounds like you may have a laptop, where that's not going to be convenient.  In that case, your best bet might be to copy the external HD to a disk image on the TC as above, then keep the HD in a safe place.
    To finish, when i enter the TC and go through the Time line how can I get a file from there and move it back to Mac hd.
    Via the "Star Wars" display, per #15 in Time Machine - Frequently Asked Questions.
    You might also want to review the Time Machine Tutorial, and perhaps browse the rest of the FAQ.

  • How to check who modified a file

    Hi is there any way to check who modified a file on Windows Server 2008? I tried to display the file's attribute on windows explorer, but it doesn't show anything.
    Thanks

    You'll need to setup auditing. This one may help.
    Auditing File Access on File Servers
    Regards, Dave Patrick ....
    Microsoft Certified Professional
    Microsoft MVP [Windows]
    Disclaimer: This posting is provided "AS IS" with no warranties or guarantees , and confers no rights.

  • Why does RCS prompt me to check out the .XPJ file when I open RoboHelp HTML?

    We just upgraded from X3 to X5 and began using RoboSource
    Control. We currently have a dedicated server machine and 1 client
    machine (we'll be adding 3 more client machines once I resolve all
    issues with this one). I have working folders set up on each
    machine so I can open the Help projects with RoboHelp HTML.
    The issue here is that I often receive the following prompt
    in a dialog box when I open a Help project in RH HTML:
    "To add version control information to this project, the
    files in the list below need to be checked out from version
    control. Do you want to check out these files?" (The only file
    listed is the .XPJ file.)
    I only seem to receive this message after I have opened that
    particular Help project on the other PC. E.g., I open Help project
    A on the Server. If I close it, I can re-open the Help project on
    that machine multiple times without receiving the message. However,
    if I then open Help project A on the client machine, I'll get the
    prompt to check out the XPJ file. If I check it out, I can then
    re-open the Help project on that machine multiple times without
    receiving the message. Of course, if check in the XPJ file from the
    client machine, I'll get the prompt on the Server machine to check
    it out the next time I go to open it up from there.
    Thoughts?

    Dirk,
    Thanks for the suggestions. I was prompted to check out the
    XPJ for one of our Help projects this morning. I clicked
    No (to NOT check out the XPJ file from the database), then
    selected the
    File Status tab, right-clicked on the XPJ file, selected
    Show Differences... and discovered that the XPJ file in the
    database had the following version control related text, whereas
    the XPJ file in the working folder on my SERVER machine did not
    (the working folder copy on my CLIENT machine matched the file in
    the database):
    Note: This code appears between a <miscproperties> line
    and a <CompileOptions> line (both XPJ files had these two
    lines).

Maybe you are looking for