cancel
Showing results for 
Search instead for 
Did you mean: 

BAPI Calling error

Former Member
0 Kudos
110

Hi all,

I am working on scenario Jdbc to SAP.In SAP ,I am using Z_BAPI_SORDER which internally calls the BAPI_SALES_OREDR_CREATEFROMDAT2 and BAPI_TRANSACTION_COMMIT. While sending the values it returns the following error message.

"Please enter Ship-To-Party or Sold-To-Party".

I am sending the following parameters..

1.Doc Type=TA

2.Sales organization =1000

3.Partner_Role=SP

4.Customer_number_1=1360

5.Material=M-14

Could anybody please help me.

Thanks,

Raghu.

Accepted Solutions (0)

Answers (1)

Answers (1)

MichalKrawczyk
Active Contributor
0 Kudos

Hi,

these are the mandatory entries for this bapi:

<b>ORDER_HEADER_IN:</b>

DOC_TYPE Sales document type

SALES_ORG - Sales organization

DISTR_CHAN - Distribution channel

DIVISION - Division

<b>ORDER_PARTNERS:</b>

PARTN_ROLE Partner role, SP sold-to party

PARTN_NUMB Customer number

<b>ORDER_ITEMS_IN:</b>

MATERIAL Material number

so as you can see your there are

DISTR_CHAN, DIVISION, PARTN_NUMB missing in your call

try adding them and check the result

Regards,

michal

Former Member
0 Kudos

Hi michal ,

Thanks for the reply.

I am sending those fields as constants.

DISTR_CHAN=10

DIVISION =00

PURC_CH_NO=0100000069(I did not find PARTN_NUMB )

Then I am getting the above errors(post1)

Thanks & Regards

Former Member
0 Kudos

Hi michal,

If partner_role

WE -


Ship-to party 99999 is not assigned to a sold- to part

AG -


No customer master record exists for customer 99999

SP -


Please enter ship to party or sold to party.

So Please try to resolve my problem

Thanks

raghu.

MichalKrawczyk
Active Contributor
0 Kudos

but you have to add PARTN_NUMB

add it to the partner role SP

and test the bapi:)

Regards,

michal

MichalKrawczyk
Active Contributor
0 Kudos

but are you adding an existing customer?

(then one that has sold to party and ship to party roles?)

Regards,

michal

Former Member
0 Kudos

Hi michal,

I did not find the PARTN_NUMB field.Thatswhy i am using PURCH_NO_C.

Regards,

raghu

MichalKrawczyk
Active Contributor
0 Kudos

PARTN_ROLE CHAR 2 Partner function

PARTN_NUMB CHAR 10 Customer Number 1

Former Member
0 Kudos

Hi michal,

Could u tell me How to check whether a customer has

sold to party and ship to party roles ?

Regards,

raghu

MichalKrawczyk
Active Contributor
0 Kudos

TCODE - XD03

and then enter customer number, company code, sales org, distribustion channel and division and then go to Sales Area data tab and partner functions

there you can see all partner functions

on my ides system there's an easy example:

customer - T-L69A01

company code - 1000

sales org - 1000

distrib chan - 10

division - 00

Regards,

michal

Former Member
0 Kudos

Hi michal,

I am using all the mandatory fields exactly what u have said. Sorry for the mistake about PARTN_NUMB.

Regards

raghu.

MichalKrawczyk
Active Contributor
0 Kudos

1. and does you customer have SP ?

2. still the same error?

Regards,

michal

Former Member
0 Kudos

1.Yes(it is SP)

2.Yes(please enter sold to party and ship to party)

Regards,

raghu

MichalKrawczyk
Active Contributor
0 Kudos

maybe you should try adding some more partner roles...

but is should work with sp...

anyway you can check this post:

http://www.sapfans.com/forums/viewtopic.php?t=25544

it may give you some more tips

Regards,

michal

MichalKrawczyk
Active Contributor
0 Kudos

you can also try adding leading zeros to your partner number up to ten values

regards,

michal

Former Member
0 Kudos

Hi michal,

Thanks for ur help.That is the main problem.I have to give leading zeros to the parner number.Now I am successfully creating sales orders.

Thanks & Regards

Reghu & Sekhar Dachepalli.

MichalKrawczyk
Active Contributor
0 Kudos

good for you Sekhar:)

Regards,

michal