cancel
Showing results for 
Search instead for 
Did you mean: 

Data selection for generic datasource

victor_yang2
Participant
0 Kudos

Hi,

I create a generic data source through infoset and I have a customer enhencement for a fild call company, which is not come from the infoset table. Can I put it in data selection? Or only the field from the inforset file can be in data selection?

Thanks

Accepted Solutions (1)

Accepted Solutions (1)

m_verbaan2
Active Participant
0 Kudos

Hi Victor,

Only fields belonging to the extract structure (for that DataSource) can be used as selection-fields. If 'Company' is not coming from the InfoSet you have to add it there or (if not possible) see if you can add the field to the Extract structure (see table ROOSOURCE, possibly a ZOXD* structure) and populate it through a user-exit (CMOD).

Hope this helps!

Regards,

Marco

victor_yang2
Participant
0 Kudos

The field is in inforset and datasource. But it is a additional field in the inforset, which I fetch from another data in CMOD.

Former Member
0 Kudos

Hi Victor,

First look if this field is filled in RSA3 when you make selection on the other fields. If it is not filled or your ABAP code is not correct or you have the flag on Hide in RSO2. If it is filled look at the format of the field, and try to insert one of these values in RSA3 selection (maybe you are not writing the values in the correct way).

Try to send your data in PSA and check again the format of the field, if it is logically fill.

Ciao.

Riccardo.

victor_yang2
Participant
0 Kudos

Hi,

It is populated in RSA3 with the right format. For example, I got company 1000, however if I put 1000 in the data selection for company, I got 0 records.

Former Member
0 Kudos

Hi Victor,

0COMPANY has 6 digit, so perhaps you have to introduce 001000.

Above all try to make this selection in InfoPackage in BW (for 1000 and for 001000), maybe is only a problem of RSA3 transaction (not the only one).

Ciao.

Riccardo.

edwin_harpino
Active Contributor
0 Kudos

hi Victor/Riccardo,

0company 10 digits ?

0000001000.

hope this helps.

victor_yang2
Participant
0 Kudos

Hi,

Thanks for reply. However is am using 0company_code, which is 4 chars. I try From 100 to 1000, still no records.

Any idea? Do I need do something in CMOD?

Thanks

victor_yang2
Participant
0 Kudos

Sorry, from 1000 to 1000. I mean.

victor_yang2
Participant
0 Kudos

And I tried all the other additional fields, they are not working in data selection.

Please help.

victor_yang2
Participant
0 Kudos

Still no answer.

Former Member
0 Kudos

Sorry Victor, I' ve finished my suggestion.

Have you tried in using the selection in Infoackage in BW instead that in RSA3 ?

Ciao.

Riccardo.

victor_yang2
Participant
0 Kudos

Yes, I tried. Same result.

Thanks

Former Member
0 Kudos

Hi there,

The reason you got right result without input company code was that you code is not responding to the selection field. Check your code for selection field. as long as you put compnay code 1000, your code is in action and it went blank back, you didn't code it yet(company code is not initial -> your code......).

Hope this helps.

Weidong

BTW. To appreciate people to answer your question is assign points to them. Good lcuk!

victor_yang2
Participant
0 Kudos

Hi,

Can you say it clealy? How to code for selection? In CMOD, I just fetch comapy_code from another table, Do I need to do anything about selection?

Thanks

Former Member
0 Kudos

yes,

There are some codes in the extractor/User Exit as follows:

if not comp_code is initial.

do your selection code here. i.e. fetch data.

endif.

(look at standard one forexample for your coding)

you can run debug mode to see where exactly these codes located.

Hope this helps.

Weidong

victor_yang2
Participant
0 Kudos

Do you have any example code?

Thanks

victor_yang2
Participant
0 Kudos

You mean if the company code is not initial, just check to decide if skip this reocrd?

Former Member
0 Kudos

Hi there,

The example code:

loop at c_t_data

If not c_t_data-comp_code(may not eaxctly the same as your field name) is initial.

In the User Exit "EXIT_SAPLRSAP_001" I guess you are suing. Look at the tables. There are 4 tables. You have to code to fill the table "C_T_DATA" by certain slection options. In your case it is company code.

modify c_t_data.

endif.

In this way, you get only the data back which the ompany code is provided.

Hope this is clear enough.

Weidong

victor_yang2
Participant
0 Kudos

Bacuase I populate the company code in CMOD, so value in the c_t_data is blank.

Should I check value in I_T_SELECT, then if check the value (company code) I got. If same, then modify the c_t_data, otherwise delete this entry?

I didn't do this beore, so please help.

Thanks

Former Member
0 Kudos

Hi there,

Sorry for replying late. Just got back to here today. Hope you solved your issue already.

Yes, you need get input value from table I_T_SELECT and using it as condition for getting data for

C_T_DATA(ABAP codes).

Weidong

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Victor,

If you have inserted this field in DataSource (RSO2), you have the enhancement in CMOD of R/3, and you are referring to selection in InfoPackage, the answer is yes, you can use this filed for data selection.

Ciao.

Riccardo.

victor_yang2
Participant
0 Kudos

No, I create additional field in the inforset and populated the value in customer exit. However it seems not working. I can select any field whic is in the inforset original files, when I select the additional field, system return 0 record from RSA3.

Former Member
0 Kudos

Hi there,

You need add field to your infoset. hope this helps.

Weidong