2018 Apr 30 11:16 PM
Hi,
I have a small and simple query, have you ever come across any SAP Standard Class dealing with users created in SAP. For example: lock, unlock, reset password etc
Man, I am fed of all these FMs and BAPIs. Any class? I used one: CL_CFX_USERS I guess, but that doesn't seem to be working.
Any suggestions?
2018 May 02 6:16 AM
You should use the BAPIs - those are the official APIs. If you use the classes behind, you'll be using parts of the standard code base that are not intended for use by customers. You do that at your own risk. If you manage to screw it up, SAP will charge you a fortune to fix.
So do what I did. Write a wrapper class to handle all user account management tasks, that hides away all those nasty BAPIs.
2018 May 01 12:35 AM
Hi,
I believe these can help you:
Regards,
Isaías
2018 May 01 8:53 AM
I am not looking for BAPIs. I need a Class, an ABAP Class.
2018 May 01 5:50 PM
Why? BAPIs are the official SAP-supported API.
2018 May 01 9:36 AM
Hello Mansoor
If you look inside BAPI_USER_CHANGE you will see all classes for example cl_identity, cl_suid_tools, cl_identity_tools etc. Just have a look at source code you will get all the classes.
Thanks
Nabheet
2018 May 02 4:16 PM
I got the classes but these are not returning me what I exactly require. Like get user data, lock user, unlock user, reset password.
Any ideas?
2018 May 03 9:20 PM
Yes. As community moderator, I must require you to answer the following questions, otherwise I will lock this question:
Any reason for hating them so much:)
Matthew Billingham 13 hours agoWhy do you have to avoid the BAPIs?
Mike Pokraka 2 days agoWhy? BAPIs are the official SAP-supported API.
2018 May 04 10:58 PM
My question isn't that bad. I got -5 for this. I guess the query is a legit one. Lol
2018 May 04 11:12 PM
well... I suggested to use BAPIs and got downvotes... Matthew suggested to use BAPIs and got several upvotes... I guess "that's life" 😛 lol
2018 May 02 6:16 AM
You should use the BAPIs - those are the official APIs. If you use the classes behind, you'll be using parts of the standard code base that are not intended for use by customers. You do that at your own risk. If you manage to screw it up, SAP will charge you a fortune to fix.
So do what I did. Write a wrapper class to handle all user account management tasks, that hides away all those nasty BAPIs.
2018 May 02 4:21 PM
Thank you for the response, I have already done that via wrapper class but needed to avoid those BAPIs instead.
2018 May 02 6:45 PM
Any reason for hating them so much:)
2018 May 03 7:27 AM
Why do you have to avoid the BAPIs?
2018 May 03 8:25 PM
Curious about this too. I can only guess that this could be some twisted logic like "SAP wants us to do OOP, so everything must be a class".
2018 May 04 10:57 PM
There is no such reason for hating these. Actually I was wondering that there are factory classes available for PO PR SES etc. So, I was guessing that there must be one for processing user details.
That's it. If there isn't any, I can't do anything about them. Was just looking OOAD approach.
I hope this clears up the clutter.
2018 May 05 9:15 AM
The OOAD approach is to write your own class. With factory methods if you like. 😁
2018 May 02 8:40 PM
Nobody is going to learn anything from a baseless "how can I do it in a non-standard way" question if you keep repeating over and over that you don't want to use the API but refuse to explain the reasons.
So to me this is a pointless question as it stands right now and gets a downvote.
2018 May 05 12:36 AM
That was harsh! Actually, you did not get the BASELESS question, what I am asking for. Looking for a STANDARD way without BAPIs. Any factory class anything?
2018 May 05 8:32 AM
Nothing harsh, at least I took the time to explain why I downvoted.
Baseless: Not having an underlying basis or foundation, groundless; unjustifiable. (Oxford English Dictionary)
You provide no basis or justification for your question, despite repeated queries. Why no BAPI? What are you trying to accomplish? What problem are you trying to solve? What do you, or anyone on this forum, gain from doing this particular task without BAPIs?
The official API that SAP provides and supports is the "STANDARD way" that most of us use. You should not avoid them without a good reason. If you just want to know how SAP does it internally, debug it. If you do have another reason not to use the BAPI, share it.
People, including myself, are trying to help. Sometimes there is a good reason not to use a BAPI, and then we try to find a solution to address that problem. That's what this community is about. But if you don't answer people's queries we can't do that, and it ends up wasting people's time instead. Five people were put off enough by it to downvote. If the reason is just for your own curiosity then that's also perfectly valid, but then please say so.