BAPI_SALESORDER_CREATEFROMDAT2: Period indicator D not defid

Question: Hi everbody,
I have jus started workin on BAPI and I have a problem while creating sales order. I am using BAPI_SALESORDER_CREATEFROMDAT2, but I am getting error "Period indicator D not defined".
Here are the parameters I am passing...which I normally input while creating from VA01.

ORDER_HEADER_IN-DOC_TYPE
ORDER_HEADER_IN-SALES_ORG
ORDER_HEADER_IN-DISTR_CHAN
ORDER_HEADER_IN-DIVISION
ORDER_HEADER_IN-REQ_DATE_H
ORDER_HEADER_IN-DATE_TYPE
ORDER_HEADER_IN-INCOTERMS1
ORDER_HEADER_IN-INCOTERMS2
ORDER_HEADER_IN-PMNTTRMS
ORDER_HEADER_IN-PRICE_DATE
ORDER_HEADER_IN-PURCH_NO_C

ORDER_ITEMS_IN-ITM_NUMBER
ORDER_ITEMS_IN-MATERIAL
ORDER_ITEMS_IN-PLANT
ORDER_ITEMS_IN-TARGET_QTY

BAPIPARNR-PARTN_ROLE
BAPIPARNR-PARTN_NUMB

The return message is "Period indicator D not defined" in Parameter
SALES_HEADER_IN.

Could any one please let me know what other parameters I have to pass .

Thnx in advance
Cheers
madhu
_________________
Madhusudhan
E-Mail: ind_madhu@yahoo.com

Answer:
Why don't you double-click on the structure, then on the field, then on the domain to go to data dictionary, and then see the allowed values?
_________________
ilya

More input data: http://abaplog.wordpress.com
Sapfans ABAP FAQ: /forums/viewtopic.php?t=94198
R's ABAP Knowledge Corner: http://www.Rard-harper.net/kb/kb.html
Function modules documentation: http://www.se37.com

Answer:
Hi,
I found the solution, I was passing the Proposed date type value as 'D' instead of 1 for BAPISDHD1-DATE_TYPE.

I have one more issue,
I am calling BAPI_TRANSACTION_COMMIT after BAPI_SALESORDER_CREATEFROMDAT2, but still the sales order is not getting updated. Even though I am getting the following messages

SALES_HEADER_IN has been processed successfully
SALES_ITEM_IN has been processed successfully
SALES_CONDITIONS_IN has been processed successfully
FOL Sales- Plant 11409 has been saved

Thnx in advance
madhu
_________________
Madhusudhan
E-Mail: ind_madhu@yahoo.com
Copyright ?2007 - 2008 www.jt77.com