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: 

User and System status of I_STATUS

Former Member
0 Kudos

Hi Experts,

How to identify whether the status selected for status inclusive i.e match code object I_STATUS is user status or system status?

As I need both system as well as user status in f4 help.I want to know how to validate whether the user has selected an system status or user status in select-option.

Thanks & Regards,

Sonali Deshmukh

5 REPLIES 5

Former Member
0 Kudos

Hi Sonali,

Just go into 'I_STATUS', it`s a collective SH. one is from system, another is from user.

Then you go into their search help exit. you will find that TJ04 stored status of system, TJ30 stored status of user. Ok, you can 'SELECT SINGLE' to identify it now.

regards,

Archer

0 Kudos

Hi Archer,

Thank you for the quick reply.

I have applied these standard serach help of status inclusive and status exclusive in my custom report.

I want to use the same functionality as in IW38 tcode for status inclusive and status exclusive.

My question is when I select the User/System status through F4 help then in my code how I will validate further whether the selected status in select-option is User Status or System status.

Thanks & Regards,

Sonali Deshmukh

0 Kudos

PARAMETERS p_status MATCHCODE OBJECT i_status.

AT SELECTION SCREEN ON p_status.

SELECT SINGLE xx INTO g_status

   FROM  tj04

WHERE ISTAT = p_status.

IF sy-subrc EQ 0.

  "it`s system status.

ELSE.

     SELECT SINGLE xx INTO g_status

        FROM  tj30

      WHERE ESTAT = p_status.

    IF sy-subrc EQ 0.

     "it`s user status.

    ENDIF.

ENDIF.

Please check above code, works for you?

Archer

0 Kudos

Hi Thank you for the reply.

I am having as select-option so select single will not work for me.

Also some status are common in both system and user, but I need to get the exact one.

Also , we select user status based on status profile..so can we determine from which status profile we have selected the user status.

For eg:

statprofile1 = CRTD - E006

statprofile2 = CNCL - E006.

Now I have selected CRTD status profile from f4 help, but in my select option I will get only E006 code.

so if I will pass this code to tj30 then i will get 2 records..but I want onlt one record which I have selected.

Is it possible?

I am debugging the standrad code for RIAUFK20 and checking how standard works.:)

Thanks & Regards,

Sonali Deshmukh

raymond_giuseppi
Active Contributor
0 Kudos

First, system will identify object type either from main program name (e.g. ORI for RIAUFK20) or from memory id PM_OBTYP (form GET_OBTYP of function group IMCH)

Then

  • For system status program get list of every available system status for the object type
  • For user status, program will get list of every available status schemes for the object type (and here you are not happy) and then get list of every available status for every scheme. (alas SCHEMA is not available as export parameter)

AFAIK only external format of status is exported (the search help exit doesn't manage DISP step, only SELECT step is handled)


Hint: Some search help as H_TJ30 also return the schema, but found none with mixed system/user status.


Regards,

Raymond