Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

BAPI

Former Member
0 Likes
557

how can we use the BAPI_SALESDOCU_CREATEWITHDIA?

what are the parameters to be used in it?

4 REPLIES 4
Read only

Former Member
0 Likes
469

hi

Text

Creating a Sales and Distribution Document

Functionality

Using this method, you can create sales documents with items, schedule

lines and item conditions.

You must enter at least sales order header data (via the structure

ORDER_HEADER_IN) and partner data (via the table ORDER_PARTNERS).

Enter the item data via the table ORDER_ITEMS_IN. You can enter the item

number manually, by filling in the relevant fields, or automatically,

corresponding to Customizing, by leaving the relevant fields blank. If

you decide to enter item numbers using R/3, no schedule lines or

conditions can be entered, as these cannot be linked to the

corresponding item.

If you are dealing with configurable items, you must enter the

configuration data in the tables ORDER_CFGS_REF, ORDER_CFGS_INST,

ORDER_CFGS_PART_OF, ORDER_CFGS_VALUE and ORDER_CFGS_BLOB.

The scheduling data can be published via the structure

SALES_SCHEDULE_IN.

Document condtions to be created can be entered via the structure

SALES_CONDITIONS_IN.

Credit card data can be published via the structure SALES_CCARD, card

identification data on the one hand, data on an authorization that has

taken place in an external system on the other.

Once you have created the sales document successfully, you will receive

the document number (field SALESDOCUMENT_EX). (Feld SALESDOCUMENT_EX).

Errors which might occur will be announced via the parameter RETURN.

Using the checkbox:

You can generate the individual components for a sales document with or

without a checkbox. If you decide on the first possibility, only fields

with unequal SPACE will be copied. In the second case (field

UPDATEFLAG), only fields which have an 'X' in the box are copied. As a

result, fields, which are preassigned to default values by the system,

can be set on SPACE again.

Notes

1. If no object references are to be written, the

(parameters) should be initialized:

BINARY_RELATIONSHIPTYPE

SALES_HEADER_IN-REFOBJECTTYPE

SALES_HEADER_IN-REFOBJECTKEY

SALES_HEADER_IN-REFDOCTYPE

rameters

SALESDOCUMENT

SALES_HEADER_IN

SALES_HEADER_INX

SENDER

BINARY_RELATIONSHIPTYPE

CONVERT_PARVW_AUART

SYNCHRONOUS

SALESDOCUMENT_EX

RETURN

SALES_ITEMS_IN

SALES_ITEMS_INX

SALES_PARTNERS

SALES_SCHEDULES_IN

SALES_SCHEDULES_INX

SALES_CFGS_REF

SALES_CFGS_INST

SALES_CFGS_PART_OF

SALES_CFGS_VALUE

SALES_CFGS_BLOB

SALES_CCARD

PARTNERADDRESSES

Exceptions

Function Group

VBAK

, better way u go to TC : se37, type the name of FM and then click on FM Documentation, u will get all the information on that FM and thr parameters.

I think this will help u.

Reward points if helpful

Regards

Nilesh

Read only

Former Member
0 Likes
469

For learning about any BAPI, the best place is to check its documentation in SE37, as thats the best help available.

For this one as given by SAP-

You must enter at least sales order header data (via the structure

ORDER_HEADER_IN) and partner data (via the table ORDER_PARTNERS).

Enter the item data via the table ORDER_ITEMS_IN. You can enter the item

number manually, by filling in the relevant fields, or automatically,

corresponding to Customizing, by leaving the relevant fields blank. If

you decide to enter item numbers using R/3, no schedule lines or

conditions can be entered, as these cannot be linked to the

corresponding item.

If you are dealing with configurable items, you must enter the

configuration data in the tables ORDER_CFGS_REF, ORDER_CFGS_INST,

ORDER_CFGS_PART_OF, ORDER_CFGS_VALUE and ORDER_CFGS_BLOB.

The scheduling data can be published via the structure

SALES_SCHEDULE_IN.

Document condtions to be created can be entered via the structure

SALES_CONDITIONS_IN.

Credit card data can be published via the structure SALES_CCARD, card

identification data on the one hand, data on an authorization that has

taken place in an external system on the other.

Once you have created the sales document successfully, you will receive

the document number (field SALESDOCUMENT_EX). (Feld SALESDOCUMENT_EX).

Errors which might occur will be announced via the parameter RETURN.

Using the checkbox:

You can generate the individual components for a sales document with or

without a checkbox. If you decide on the first possibility, only fields

with unequal SPACE will be copied. In the second case (field

UPDATEFLAG), only fields which have an 'X' in the box are copied. As a

result, fields, which are preassigned to default values by the system,

can be set on SPACE again.

Notes

1. If no object references are to be written, the following fields

(parameters) should be initialized:

BINARY_RELATIONSHIPTYPE

SALES_HEADER_IN-REFOBJECTTYPE

SALES_HEADER_IN-REFOBJECTKEY

SALES_HEADER_IN-REFDOCTYPE

Regards,

Rohit

Read only

Former Member
0 Likes
469

Hi

Here is the function module documentation.

This might help u.

Short Text

Creating a Sales and Distribution Document

Functionality

Using this method, you can create sales documents with items, schedule

lines and item conditions.

You must enter at least sales order header data (via the structure

ORDER_HEADER_IN) and partner data (via the table ORDER_PARTNERS).

Enter the item data via the table ORDER_ITEMS_IN. You can enter the item

number manually, by filling in the relevant fields, or automatically,

corresponding to Customizing, by leaving the relevant fields blank. If

you decide to enter item numbers using mySAP ERP, no schedule lines or

conditions can be entered, as these cannot be linked to the

corresponding item.

If you are dealing with configurable items, you must enter the

configuration data in the tables ORDER_CFGS_REF, ORDER_CFGS_INST,

ORDER_CFGS_PART_OF, ORDER_CFGS_VALUE and ORDER_CFGS_BLOB.

The scheduling data can be published via the structure

SALES_SCHEDULE_IN.

Document condtions to be created can be entered via the structure

SALES_CONDITIONS_IN.

Credit card data can be published via the structure SALES_CCARD, card

identification data on the one hand, data on an authorization that has

taken place in an external system on the other.

Once you have created the sales document successfully, you will receive

the document number (field SALESDOCUMENT_EX). (Feld SALESDOCUMENT_EX).

Errors which might occur will be announced via the parameter RETURN.

Using the checkbox:

You can generate the individual components for a sales document with or

without a checkbox. If you decide on the first possibility, only fields

with unequal SPACE will be copied. In the second case (field

UPDATEFLAG), only fields which have an 'X' in the box are copied. As a

result, fields, which are preassigned to default values by the system,

can be set on SPACE again.

identification data on the one hand, data on an authorization that has

taken place in an external system on the other.

Once you have created the sales document successfully, you will receive

the document number (field SALESDOCUMENT_EX). (Feld SALESDOCUMENT_EX).

Errors which might occur will be announced via the parameter RETURN.

Notes:

If no object references are to be written, the following fields

BINARY_RELATIONSHIPTYPE

SALES_HEADER_IN-REFOBJECTTYPE

SALES_HEADER_IN-REFOBJECTKEY

SALES_HEADER_IN-REFDOCTYPE

Thanks,

Deepti

Read only

Former Member
0 Likes
469

check...

this has solution which u can use it.

reward if useful.