Friday, January 20, 2006

Transaction code authority check

Transaction code authority check

 

 
The following code demonstrates how to check that a user has the correct authority for a particular 
transaction code. Useful to check if a user has the correct authority before executing a transaction via 
BDC input.

 

 

 
authority-check object 'S_TCODE'
                id     'TCD' 
                field  'SM35'.
 
if sy-subrc ne 0.
*   User does not have authority for transaction SM35!!!
endif.

 

 

Regards,

Ankur Bhandari

Authorisation trace analysis 1. Open two sessions

Authorisation trace analysis

1. Open two sessions
2. Execute transaction ST01 in one of the sessions
3. Select the authorisation checkbox, note the other traces 
   you can perform (SQL, RFC, Table Buffer etc)  
4. Click the 'Trace On' button
5. Within your other session execte the transaction/report 
   you want to trace or get the user in question to do it
6. Return to the session where you turned the trace on and 
   click on 'Trace Off' otherwise it will continue to record 
   all athorisation checks
7. Click on the 'Analysis' button
8. Enter appropriate data into selection screen such as 
   Username, type of trace records (i.e. Authorization check)
9. Click on the Execute button. 
10. Report displaying trace results will now be displayed  
 

 

 

Regards,

Ankur Bhandari

Modify thru SE16

Debug SE16 to allow record changes

 

 
If you are not authorised to change table entries or the table has been create without table maintenance 
allowed (all SAP tables), you can still change entries via data browser (SE16) by means of debugging. The 
process is as follows:

 

 

 
1. Display record entries for desired table via SE16 or SE11.
2. Select record which requires updating by highlighting it and pressing the display icon (glasses, F7).
3. Type /h in command box and press enter. 
4. Now press enter again and you should enter debugging mode
5. Change the value of code from ‘SHOW’ to ‘EDIT’, remember to press the ‘change field contents’ 
    icon (pencil) in-order to store new value.
6. Press F8 (execute) to leave debug.
7. You should now have change access to the selected record. 
8. Hit ‘SAVE’ to save any changes. 
9. Remember there is a reason why you can’t do this without debugging it, one reason being that it could 
    introduce inconsistencies in the table data.

 

 

Regards,

Ankur Bhandari

Thursday, January 12, 2006

Tables for transport proposal

CTWFACTLOG                     Transport Proposal: Action Log          

CTWFNUMBER                     Transport Proposal: Number Assignment   

CTWFPROPOS                     Transport Proposal: Header              

CTWFREQUST                     Transport Proposal: Requests for Import 

CTWFTARGET                     Transport Proposal: Target Systems/Target

 

Regards,

Ankur Bhandari

Saturday, January 07, 2006

Transaction SU21 for finding any authorization objects.

Transaction SU21 for finding any authorization objects.

 

Regards,

Ankur Bhandari

 

Wednesday, January 04, 2006

List of commonly used function modules

Drop down List function module

VRM_SET_VALUES can be used for drop down lists.

 

Regards,

Ankur Bhandari

SAP Consultant

Alv variants copy

Try using LVC_VARIANT_SELECT and LVC_VARIANT_SAVE fms.

First call LVC_VARIANT_SELECT to read variant from the first program and then call LVC_VARIANT_SAVE to save it for the second program.

Take a look at report BCALV_GRID_11 for reference

 

Refer to the follwoing SAP Tables and see if you have some luck.
==========================================================

LTDX --> Generic storage of display variants
LTDXD --> Default display variants
LTDXS --> SAP Default Display Variants
LTDXT --> Display variant texts

==========================================================

The idea is to try and manipulate the table entries for various users.

 

S_ALV_LAYO is the authorization which needs to be used.

 

Regards,

Ankur Bhandari