cancel
Showing results for 
Search instead for 
Did you mean: 

Authorization in Pricing

Former Member
0 Kudos

Dear all SAP experts,

I need to have the ability to assign a pricing condition profile to a specific user so that he/she can only see certain pricing conditions in the sales order. To be clear for example there are 2 condition types ZSD1 & ZSD2. User "X" should not be able to see the condition type "ZSD2" & user "Y" should not be able to see condition type "ZSD1". Also I want that profile/object have the option for display or change abilities within the sales order.

How can I do this in SAP? Please guide me.

Regards,

Allabaqsh G. Patil

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

hi,

Often there is a requirement for making a condition type (price, discount etc) non-modifiable for some-users and modifiable for others using the same SAP system or modifiable for certain document types (say OR ie Standard Sales Order) and non-modifiable in another order type (say CR ie Credit Memo Request). In standard SAP this is not possible. Using the controls for the condition-type (V/06 transaction) we can either make a condition type

1. No Limitations

2. A : Free

3. B : Automatic Entry has Priority

4. C : Manual Entry has Priority

5. D : Not possible to process manually

Selecting any one of this option makes the condition type uniform across all document type and for users. Often the requirements are like for a group of users the condition type should behave like C option, for another group like D or for a specific document type it should be A and for others D.

One of the easiest way to achieve this is through the user-exit USEREXIT_PRICING_PREPARE_TKOMP in the include MV45AFZZ.

The following code will make the condition type ZSD1 modifiable for user XXXX and non-modifiable for all other users.

FORM USEREXIT_PRICING_PREPARE_TKOMP.

DATA : i_T685A TYPE STANDARD TABLE OF T685A WITH HEADER LINE.

IF SY-UNAME = 'XXXX'.

LOOP AT XKOMV.

IF XKOMV-KSCHL = 'ZSD1'.

SELECT * FROM T685A INTO TABLE I_T685A WHERE KSCHL = 'PR00'.

READ TABLE I_T685A WITH KEY KSCHL = XKOMV-KSCHL.

I_T685A-KMANU = 'C'.

MODIFY I_T685A INDEX SY-TABIX.

MODIFY T685A FROM TABLE I_T685A.

REFRESH I_T685A.

ENDIF.

ENDLOOP.

ELSE.

LOOP AT XKOMV.

IF XKOMV-KSCHL = ZSD1'.

SELECT * FROM T685A INTO TABLE I_T685A WHERE KSCHL = 'PR00'.

READ TABLE I_T685A WITH KEY KSCHL = XKOMV-KSCHL.

I_T685A-KMANU = 'D'.

MODIFY I_T685A INDEX SY-TABIX.

MODIFY T685A FROM TABLE I_T685A.

REFRESH I_T685A.

ENDIF.

ENDLOOP.

ENDIF.

ENDFORM.

Edited by: shankar on Feb 26, 2008 4:31 PM

Former Member
0 Kudos

Hi Shankar,

We have exactly the same problem, but what I don't undertand in your code is, that you are actually modifying the std. SAP config table T685A based on the authorizations of each user with your statement

MODIFY T685A FROM TABLE I_T685A.

What this means is, that if user A has the authorization then you are changing the configuration table for this condition type to C. Then when user B creates or changes another order afterwards and does not have the authorization, then T685A-KMANU will still have the entry for C for user B.

How does this T685A-KMANU value ever get changed back to its original value, so that a user withaut the authorization still sees a 'D' value in T685A-KMANU? How can this table T685A be changed based on a user's authorizations without affecting all the other users, who might have different authorizations and might be running through your logic simultaneously?

Could you please explain?

Thanks,

Peter

Former Member
0 Kudos

hello, friend.

there is sapnote 106521 specifically for your requirement. this needs the assistance of a BASIS or ABAP consultant.

what the sapnote tells you is how to create an authorization object by reading the line entries in your pricing procedure (reading the condition types, sub-totals, totals, etc.). you can then limit access to these authorization objects.

i have to tell you, though, that not all people would find this satisfactory. we have tried it and, in our case, a smart user can still find ways to view, say, the costs of a material and the values in a material document. so you would have to test this in your sandbox to see if this meets your requirements.

regards.

Former Member
0 Kudos

Hi,

I can think of an alternative, just see if its feasible.

In V/06 you can make ZSD1 and ZSD2 - manual changes as D - Cannot be processes manually.

Now you can have authorizations object assigned to a profile which will be assigned to a user so that he can make changes only for ZSD1.

And the other user can do it for ZSD2.

In this way even if they could see what are the rates, they just maintain rates only for their assigned condition types.

Reward if you think this could work.

Regards

Ravi