Application Development 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: 

CALL TRANSACTION CC31

Former Member
0 Kudos

Hi all,

for my diploma thesis I am looking for a way to create ECRs and assign objects to them programatically. My first idea was to use CS_BI_ECR_CREATE_BATCH_INPUT but this did not work. Now my second approach is to write an own BAPI basically calling transaction CC31. I am completely new to ABAP so these are my questions/ideas:

1. Create a BAPI

importing:

change header (RC29A)

table of change object types

table of assigned object

Exporting:

change number (CHAR72)

2. within this bapi create BDCDATA which is used in

3. CALL TRANSACTION 'CC31'

USING BDCDATA

MODE 'N'

UPDATE 'S'.

Questions:

1. is this possible? (my transaction needs to be called remotely)

2. how can I access the autogenerated change number in order to return it?

Thanks in advance, Filip

12 REPLIES 12

former_member188685
Active Contributor
0 Kudos

Questions:

<i>1. is this possible? (my transaction needs to be called remotely)</i>

No it is not possible , since it is associated with Screens, you will get Short Dump.

Regards

vijay

0 Kudos

Hi,

how can I create an ECR then?

Thanks, Filip

0 Kudos

Did you try using BDS_BUSINESSDOCUMENT_CREATEF?

or RFC_CREATE_CHANGE_MASTER?

Regards,

ravi

0 Kudos

Hi,

you should look for alternatives Like RFC, or BAPI's to create ECR.

Regards

vijay

0 Kudos

Hi,

unfortunately I can't use RFC_CREATE_CHANGE_MASTER because I want to Create the ECR from Java using JCo.

How would I use BDS_BUSINESSDOCUMENT_CREATEF to create ECRs?

Thanks, Filip

PS: I've been looking for such BAPIs in SE37 but except for CS_BI_ECR_CREATE_BATCH_INPUT and CS_BI_ECR_CHANGE_BATCH_INPUT I wasn't able to find any BAPIs. I can already create ECRS using CS_BI_ECR_CREATE_BATCH_INPUT but I can't assign objects to them

Message was edited by: Filip Polsakiewicz

0 Kudos

Hi Filip,

What stops you from calling the rfc using JCo.

I think it is quite possible to call any rfc from Java applications using JCo calls .

Regards,

ravi

0 Kudos

Hi,

the problem is that I am calling my BAPI from another server application. There is no SAPGui installed on that machine so that I can not use RFC BAPIs.

Regards,

Filip

0 Kudos

See if the baoi BAPI_ECMORD_CREATE is related to your problem.

Check the Function module documentation to know its use.

Regards,

ravi

0 Kudos

hi,

<b>BAPI_ECMORD_CREATE</b>, is available only in ECC 5.0 versions. not in older versions.if you are on ECC5.0 version then it is well and good. that will create the ECR.

regards

vijay

0 Kudos

Hi,

first of all thanks for all your answers.

Unfortunately our system does not have BAPI_ECMORD_CREATE installed (it's a 4.6C system).

I already managed to Create an ECR using CS_BI_ECR_CREATE_BATCH_INPUT. The only thing that does not work is assigning objects to that ecr

Regards, Filip

Former Member
0 Kudos

Well I think u can definitely use Call transaction to create the document inside a BAPI. I say u give it a shot…

-Kiran

Former Member
0 Kudos

For retriveing the document number use the below syntax.

CALL TRANSACTION 'IW36'

USING i_bdcdata

OPTIONS FROM opt

MESSAGES INTO i_messtab.

You will find the document number in the I_MESSTAB table.

-Kiran