POSTing escpaded char data and &'s??

I'm trying to send data via a CGI POST request but I'm running into to a couple problems.
First, a portion of the data comes from static strings within my code that have double quotes within the strings. I escape the quotes with a backslash but the backslash is showing up within the POST data within my PHP script. If I simply display the data that PHP sees it looks exactly like the static strings, backslashes and all. This is how I'm trying to accomplish the post currently:
URL lurl_bene;
HttpURLConnection lcon_bene;
BufferedReader in;
PrintWriter out;
lurl_bene = new URL("http://192.168.100.5/cgi-bin/sync.php");
lcon_bene = (HttpURLConnection)lurl_bene.openConnection();
lcon_bene.setDoOutput(true);
lcon_bene.setRequestMethod("POST");
out = new PrintWriter(lcon_bene.getOutputStream());
out.write("sync=" + lsb_xml.toString()); // lsb_xml is a preconstructed string buffer
I've tried outputting the string to standard out and writing it out to a file and neither of them display the backslahses.
Secondly, The POST data stops as soon as it hits an &. I don't know if this is Java or PHP but if I print the contents of the POST variable within PHP it contains everything up to, but not including the first ampersand. I tried creating a simple html form try to send the data with a browser and the ampersands go through just fine. Do the browsers automatically escape the ampersands within the data you are sending?
Thanks in advance
- Frustrated

First of all, I know nothing about CGI or PHP. Secondly, I'm no expert at Java (I want to cover my bases here).
That said, I believe that using \" will force Java to use the char '"', there will never be any record of a \ being used. If you were to get the bytes of the String, and go through one by one, you would never find the char code for \.
So, I guess it would have to be something to do with the PHP script.
Second, I've never heard of java choking on a & in a string. But the easiest way to find out is to test it yourself. Get it to print out a & in the same context you wanted PHP to (or perhaps the same String) and see if Java handles it. I strongly suspect it will. So again (sorry) I'm gonna have to point the finger at PHP.
Anyway, this is all speculation, and I only post because no one else has.
Good luck,
Radish21

Similar Messages

  • How to fetch post goods issue date and sales order creation date

    Hi All,
    How to find out the difference between SD Sales Order Item Creation Date and final Post goods issue Date. I would like to know how to fetch those dates and what is the relationship between the tables from which i will get the dates.
    Please let me know the solution .
    Thanks in advance.

    Hi,
    Sales order creation date is when u raise a sales order in favor of the customer using VA01.......using ATP logic system purposes the material availability date....
    after saving ur sales order...when u raise the Delivery using VL01n  w.r.t to OR...than u have to perform picking ....In the picking Tab...specify the amount to be picked than press Post Good Issue....means the goods left the company premises ..
    You can the fetch the values using tables-  Use T code   SE12  or SE16
    Vbak-----order header
    Vbap-----order item
    Vbek-----order schedule line
    Likp-----Delivery header
    Lips----Delivery item

  • Reversing A/P Invoice posted with wrong date and inventory cost adjustment

    Here's the situation:
    We had a PO dated 9/1/09 for items with a cost of $14.50, a Goods Receipt was entered 9/15/09 for the items with the same cost on the PO of $14.50.  Somehow the order got lost in the mix and the AP invoice wasn't entered until today, with a posting date of 1/21/10 and the cost was corrected per the original vendor invoice to the right amount of $19.33.  The invoice was actually dated 9/15/09.  This resulted in hitting the vendor, purchases clearing and the inventory account (for the cost adjustment) in January 2010 when it should have occurred in September 2009.
    The inventory itself has come and gone in the time between the GR and when the invoice was done with the incorrect date.  Normally I would try to reverse the transaction with a Credit Memo and start over, however since the inventory side happened so long ago, I don't see any way of easily going backwards.  I thought about doing service CM/invoice but what I am most concerned about is having the inventory valuation occur properly at the correct time.  I'm not sure how to go about this.
    Using SAP B1 2007A PL42 with moving average inventory.
    Any thoughts would be appreciated.

    Nicole,
    I am afraid you may not have ability to do the adjustment based on historical date that long times ago.  You know, the moving average has limited calculation based on current quantity and cost.  There are no options to go backward especially new year is coming.
    Thanks,
    Gordon

  • Posting date and posting periods

    HI Experts,
    I am practicing IDES for SD. While using T VL02N for post good Issue I got this error:
    <b>Posting only possible in periods 2006/12 and 2006/11 in company code 1000
    Message no. M7053
    Diagnosis
    The posting date entered is not within one of the permitted posting periods (current period/previous period).
    This can be due to one of two reasons:
    The correct current period has not been set in the system.
    For the system, the first of the entered periods is the current period. At the beginning of a new period, your systems administrator must change the current period in the material master record, using the function "Shift periods". This has not yet been done.
    You have entered a wrong date in the field "Posting date".
    Procedure
    Check the posting date and correct it if necessary. If your input is correct, inform your systems administrator that the "period shifting" (period-end closing) process has not yet been completed. Copied from M8022</b>
    I don;t think there is problem with my posting date. Can someone guide me on how solving this
    Thanks
    Yael

    Go to OMSY and check the periods are current peiods or not to ur comp code?
    If it is not the current period.
    close the posting period by going to MMPV.
    let us say comp code EG, YEAR-2006  PE-6
    so you have to close the posting periods for all months till this month.
    from comp code-EG
    To comp code- EG
    period-7
    fiscal year-2006
    repeat the same but with period-8(month) 9,10,11,12,
    and do the same for 2007 too till you get the current month in OMSY T-Code.
    you need to do close the period end of every month.
    thank you
    chaitanya

  • Default key date, Document date and posting date needs to be changed automa

    Hi Experts,
    The user wants to create a variant for Foreign currency valuation, wherein the default key date, Doc date and Posting date needs to be changed every month automatically. Is it possible?
    Please let me know your thoughts.
    Warm regards,
    Murukan Arunachalam

    Hi
    Please follow this process.
    Only specify fields that should be changed
    Select these fields by entering an X in the checkboxes
    Enter a U in the UPDATEFLAG field
    Always specify key fields when changing the data, including in the checkboxes
    The configuration is an exception here. If this needs to be changed, you need to complete it again fully.
    Maintain quantities and dates in the schedule line data.
    1. Minimum entry:
    You must enter the order number in the SALESDOCUMENT structure.
    You must always enter key fields for changes.
    You must always specify the update indicator in the ORDER_HEADER_INX.
    2. Commit control:
    The BAPI does not run a database Commit, which means that the application must trigger the Commit so that the changes are read to the database. To do this, use the BAPI_TRANSACTION_COMMIT BAPI.

  • Goods Receipt and Goods Issue - Posting Date and Document Date Problem

    Hi All,
    I was using SDK to build own add on to insert Posting Date and Document Date under Inventory> Inventory Transactions> Goods Receipt and  Inventory> Inventory Transactions> Goods Issue, but the UI Screen Posting Date and Document Date shown current date.
    My SAP Business One version was 2007A SP00 PL42 and alreadly upgrade to SP05.
    End up result still the same.
    Is there someone can help me?
    Thanks you.
    Best Regards,
    danny

    Hi there,
    I already solve it by myself.
    Actually is i call the initialization twice:
    Company.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oInventoryGenEntry)
    Thats what make this problem happened.
    Sorry.
    Best Regards,
    danny

  • FA-retirement-Asset value date and posting date are not in same fisc year

    Hello,
    I would like to post retirement in the new fiscal year but with asset value date in the previous year so that NBV is calculated correctly. It is not possible neither in ABAON nor in ABAVN with any transaction type.
    I always get message 'Asset value date and posting date are not in same fiscal year'.
    Is there any way how to handle this?
    Thank you,
    Jan

    Hi,
    I have tried this but the settings of our Depr keys works in the way. That if you use asset value date in the new month it will calculate depreciation for the whole month.
    This means if I retire with asset value date 31.12.2008 - NBV will be calculated as at 31.12.2008.
    If I retire with asset value date 1.1.2008 - NBV will be calculated as at 31.1.2009.
    Thank you anyway!

  • Asset value date and posting date are not in same fiscal year

    Hi,
    Our business user has created an asset under an incorrect asset class, which he is trying to transfer to a new asset whcih was created under correct asset class. However system is restricting user with the error message "Asset value date and posting date are not in same fiscal year". Can you please advise me how we can proceed further with this error.
    Regards,
    Asam.

    Hi,
    To transfer one asset to another asset within a company code can be done through ABUMN only.
    While doing this transfer you have enter the document date, posting date, and value date for the transaction, but all these dates should be in same fiscal year only.
    In your case you must have been entered the dates for asset value date and posting date , and these two dates are in diff financial years.
    Please make sure that both the dates are in same FY.
    Hope this will fix your issue.
    Thanks,
    Srinu

  • Posting date and System date

    Hi SAP experts ,
    I am troubleshooting one system  and I am kind of getting lost ...
    Let me explain the scenario:
    Posting period set up
    Posting date : 01-14-09
    Sytem Date :01 -01-09
    After checking all the information , I ran my period end closing .. I ran a comparison report between 12/31/2008 and 01/01/2009 .
    My balance sheet matches with when I ran by posting date and my balance sheet is way off (especially retained earning )if ran by system date .
    I can get the differnce in amount but was unable to track the exact transaction .Some of the adjustment have been done in this system using system date .
    Any queries that will help me to track  ?  I have used this
    SELECT
    T0.TransId, T1.Account, T1.Taxdate, sum(T1.Debit-T1.Credit) Balance FROM OJDT T0  INNER JOIN JDT1 T1 ON T0.TransId = T1.TransId WHERE T0.TransType = 30 GROUP BY T0.TransId, T1.Account,T1.Taxdate
    But not much of help to target easily ...
    Any advise on this ...Should I consider if balance sheet is correct by posting date , it is fine ..
    Thank you
    Bishal
    Edited by: BIshal Adhikari on Jul 28, 2009 3:52 PM

    Hi Bishal,
    I believe balance sheet by posting date is correct.  System date is only kept for system to show the audit trail when you actually added the document.
    Thanks,
    Gordon

  • Show SQL issue on Posting Date and Aging Date

    Hi Folks,
    When I am running a report >>> the report pops up with the some parmeters >>
    In my scenario u201CAging Dateu201D forumla is calculated as the last day of the every month.
    if month (currentdate) = 1 then date((year(CurrentDate)-1),12,31) else
    date(year(currentdate),month(CurrentDate),1)-1
    Example : if 9( 23 sep 2010 ) = 1 then date ((2010(23 Sep 2010)-1),12,31) else date(2010(23 sep 2010),9( 23 Sep 2010),1)-1.
    Issues :
    For some reports the Aging Date parameter is poping up but for some of the reports the Aging Date forumla is calculating in the behind based on the u201CPost Dateu201D.
    Here is my Record Selection :
    (not isnull({CLARITY_TDL.SERV_AREA_ID}) and {CLARITY_TDL.SERV_AREA_ID}
    in {?Service Area} or 0 in {?Service Area}) and
    (not isnull({CLARITY_DEP.SPECIALTY}) and {CLARITY_DEP.SPECIALTY} in {?Specialty} or {?Specialty} =
    "Specialty(s)" or {?Specialty} = "NONE") and
    (not isnull({CLARITY_TDL.PERFORMING_PROV_ID}) and {CLARITY_TDL.PERFORMING_PROV_ID} in {?Service Provider} or
    {?Service Provider} = "Provider(s)" or {?Service Provider} = "NONE") and
    {CLARITY_TDL.POST_DATE} = {@Aging Date}and
    [color=darkred]{CLARITY_TDL.DETAIL_TYPE} in [60, 61] and
    {CL_EMP_CLARITY.USER_ID} = CurrentCEUserName
    Moreover when I check Show SQL for the where clause
    CLARITY_TDL"."SERV_AREA_ID" IS NOT NULL AND "CLARITY_TDL"."SERV_AREA_ID"=10 AND "CLARITY_TDL"."POST_DATE">={ts '2010-08-31 00:00:00'} AND "CLARITY_TDL"."POST_DATE"<{ts '2010-09-01 00:00:00'})
    AND ("CLARITY_TDL"."DETAIL_TYPE"=60 OR "CLARITY_TDL"."DETAIL_TYPE"=61) AND "CL_EMP_CLARITY"."USER_ID"=''
    I donu2019t know why the post date is going in between the date/time ranges. I am scrating my head to understand the things to work. Please help me out.

    Not sure what you are trying to do here
    (not isnull({CLARITY_TDL.SERV_AREA_ID}) and {CLARITY_TDL.SERV_AREA_ID}
    in {?Service Area} or 0 in {?Service Area}) and
    (not isnull({CLARITY_DEP.SPECIALTY}) and {CLARITY_DEP.SPECIALTY} in {?Specialty} or {?Specialty} =
    "Specialty(s)" or {?Specialty} = "NONE") and
    (not isnull({CLARITY_TDL.PERFORMING_PROV_ID}) and {CLARITY_TDL.PERFORMING_PROV_ID} in {?Service Provider} or
    {?Service Provider} = "Provider(s)" or {?Service Provider} = "NONE") and
    Probably better to right these on these lines
    (If {?Service Area} not equals 0 then not isnull({CLARITY_TDL.SERV_AREA_ID}) and {CLARITY_TDL.SERV_AREA_ID}
    in {?Service Area}  else true) and
    NB Typed not equals as symbols disappear
    This means nothing in SQL and will cause whole clause to be evaluated locally and not on database
    or {?Specialty} =
    "Specialty(s)" or {?Specialty} = "NONE")
    I am not sure what you are trying to do so can not offer an alternative.
    Ian

  • Issue In posting date and Due Date

    Hello All,
    my client is creating a GRPO and manually changing the Posting, And doc date. Then by using Copy to utility he is creating A/P Invoices
    There system automatically shows the Posting date, Document Date as of current date(That is what system behavior is ). But now he wants that system should pick all his dates from Base doc i.e GRPO
    So i want to know that is this possible through some query or FMS
    if yes then please suggest me for the same
    Regards,
    Bhushan

    Hi,
    I don't have $38.10.number in my query. Where did you get this field?
    please follow below steps:
    1. Run above query in generator. Sure it gives an error message and ignore this message.
    2. save it under query manager
    3. Assign this FMS at AP invoice posting date and set auto refresh when customer vendor refer is changed.
    Thanks & Regards,
    Nagarajan

  • Invoice verification Invoice date,Posting date and Baseline Date

    Hi Sap Gurus
    Pls Tell Me in detail what Dates should be entered at MIRO transaction,
    Invoice date,Posting date and Baseline Date
    i presumed that the date on the Invoice slip will be Invoice date,
    But in the Invoice the Date is very long back, say a month Older,
    the month of Posting as Posting date, but any posting Date made in MIRO will be Paid after 2 or 3 months so in this case what should be the Posting date.
    at Base line date in the present company Senario the Discount on Vendor payment is literally valid for all the time , say
    In Invoice if the condition is 10% discount if paid in 30 days is given.
    but in actual sense the Vendor is paid 10% less even if he is paid after 4 or 6 months also, so in this case what should be the Entry in Baseline date
    another senario is the vendor has sent only one Invoice for 2 POs how can this be accomadated in SAP
    Pls suggest its Urgent,
    Age may have a Bar, But Points No Bar
    Thanks and Regards
    Sathish

    Hi
    LIV is nothing but You are getting Invoice from the Vendor for your PO   and GR.....and you are checking the Invoice for Price, Qty,Amount etc. by refering the PO  and posting the Invoice...
    Invoice Date : 
               The date of Vendor' Invoice...ie) Date at which the vendor Raised the invoice for his supply against your PO...
    Posting Date :
       The Date at which you actually Verifying Vendor's Invoice and doing the Posting...
    base line date :
        Generally the Posting Date...
    The Imp. of Baseline date is for eg)
    If in the Payment Terms if some conditions are maintained like say
    10% Discount for Payment With in 30 days, if
    PO created on 01.11.2007.
    GR done at 10.11.2007.
    Invoice slip Received at 30.11.2007 but having the Date on it as 20.11.2007...
    So as per your terms you will get 10% Discount if you make the payment on or  20.12.07....
    Here if you keep  inv. Date: 20.11.2007  and Posting Date : 30.11.2007  and Baseline Date as  30.11.2007 ( you cannot maintain baseline date earlier than  Posting date)....even though as per terms the you are  eligible for discount if you make the payment on or before 20.11.2007.....as per the system you are still eligible to get the Discount if you make payment on or 30.12.2007( since you have maintained baseline date as 30.11.2007)...
    this way Baseline date is Importane...
    Generally we use to maintain always Posting Date as Baseline date....
    It is advantageous..
    Reward if useful
    regards
    S.Baskaran

  • Difference between doc date,posting date and invoice date

    hi bw guys
    can someone give a brief on the difference between doc date,posting date and invoice date.and the invidual definitions
    thank you

    Hi,
    Posting Date: Date which is used when entering the document in Financial Accounting or Controlling. The posting date can differ from both the entry date and the doc date.
    Document Date: The document date is the date on which the original document was issued. Ex: Inv date, Bill date etc.,
    Invoice Date : Usually the date when goods are shipped. Payment dates are set relative to the invoice date.
    -Vikram

  • Difference between Posting Date and Posting Day

    In Accounting Document Header table BKPF, there are 2 fields: BUDAT (Posting Date) and PSOBT (Posting Day), both of DATS type. What is the difference between the two?
    Why is that substitutions and Business Transaction Events allow changing of Posting Day (PSOBT) and not BUDAT (Posting Date)?
    In that case, how can I change the Posting Date of a document based on certain rules?
    Thank you.

    Hi,
    13 period is a special accounting period, so the situation you described is perfectly normal. The reversal document will be posted in the same period.
    You can read more about special periods here:
    http://help.sap.com/erp2005_ehp_03/helpdata/EN/96/8b2fef43ce11d189ee0000e81ddfac/frameset.htm
    Regards,
    Eli

  • Post date and due date

    Hi all,
    can any  tell me what you mean by 'posting date' and 'net due date' and' clearing date'?
    what is the difference between them?
    Table is-BSID
    BUDAT-posting date
    ZFBDT-Baseline date for due date calculation
    AUGDT-clearing date.
    thank u
    sunny.

    BUDAT-posting date
    -> to determine the book-period (bkpf-monat)
    ZFBDT-Baseline date for due date calculation
    -> determine date when an obligation becomes due
    due date = zfbdt + bsik-zbd1t (or ZBD2t or ZBD3t)
    AUGDT-clearing date
    -> date when open-item becomes a cleared item
    by payment or reversal or...
    A.

Maybe you are looking for