‎2012 Feb 15 6:43 AM
Hello,
In our PRD, there is a custom program YVU_CORR_MATNR (Y-program)
Is it possible to deactivate this program. (rather than deleting)
How can we check the status of this program? (Activate or Inactivate)
(There is no t-code assign to this custom program)
I have cheeked in se38,
Under "Program" menu , it has "Active <-> Inactive"
When click on this is displays;
" YVU_CORR_MATNR does not have any inactive versions"
Kindly let me know, how to proceed with this
regards,
zerandib
Edited by: zerandib on Feb 15, 2012 7:44 AM
‎2012 Feb 15 6:49 AM
This program is active in your PRD system.
Since it doesnt have any tcode assigned,no one can execute it other than from SE38.
So why do u want to deactivate it in PRD directly ?
‎2012 Feb 15 6:49 AM
This program is active in your PRD system.
Since it doesnt have any tcode assigned,no one can execute it other than from SE38.
So why do u want to deactivate it in PRD directly ?
‎2012 Feb 15 6:53 AM
hi Gautham ,
Is it possible to some other program to execute this.?
There are some inconsistencies in MBEW table. ..
when examining , SAP support informed that "YVU_CORR_MATNR which are also potential cause of inconsistencies "
So they have asked to deactivate/remove this program.
Is it possible to deactivate this prog.
regards,
Zerandib
‎2012 Feb 15 6:57 AM
Yes, this program can also be called from some other programs.
Do a where used list to find out all the places it has been used.
If it can cause inconsistencies then you can comment the code in DEV system
and transport to PRD instead of deleting the program.
If you dont want to comment the code,use an authorization object and
restrict access to other users from executing it.
‎2012 Feb 15 7:01 AM
Hi
you can only delete a program, there is no sort of deactivatin a program in ABAP. Check the usage of your program in other objects if no where used delete it, if it has been used in some other objects remove the usage and delete the program.
‎2012 Feb 15 4:04 PM
Is it possible to some other program to execute this.?
You can do a where used list to see if it is called from another program.
If OSS says get rid of it, nuke it.
Rob
‎2012 Feb 15 6:51 AM
HI,
If it a executable program then you can do is in event
at selection-screen.
if sy-ucomm eq 'ONLI'.
message e000(8i) with 'Program cannot be executed'.
endif.
Thanks,
Madhukar Shetty
‎2012 Feb 15 7:54 AM
Why don't you just comment out all the code in the report except for the first Report statement ?
‎2012 Feb 15 11:39 AM
If it is not required any more and even potentially harmful, then delete it in DEV system and transport through the landscape. Everything else, whether technically possible or not, is a waste of time, in my opinion (unless there are good reasons to keep it, that you did not tell us about yet)
Even if you would need it again later you can retrieve it from the version database via SE38.
Thomas
‎2012 Feb 15 11:58 AM
Hi zerandib
This is not possible to deactivate a program.
And option to switch between Ative <-> Inactive only works when you have one active version and a modified version.
Best regards
‎2012 Feb 15 12:53 PM
If you don't wat to delete it, comment the code out. If it is called from somewhere, the call won't fail, but nothing will hapen.
If you comment it out, it is safe to keep it, but as Thomas said delete it would make more sense.
Cheers Otto
‎2012 Feb 15 2:23 PM
What Thomas said. :-).
Rob
Edited by: Rob Burbank on Feb 15, 2012 9:23 AM
‎2012 Feb 15 3:57 PM
Yup
Or if it is a case where only restricted access is needed, then assign some authorization roles to it.
Or if SAP suggests that its causing inconsistencies then why hesitating to delete?
Regards,
Joe
Edited by: lazarus_joey on Feb 15, 2012 4:58 PM
‎2012 Feb 15 8:12 PM
Hello zerandib,
Program details are stored in table: REPOSRC.
Field R3STATE corresponds to program status. "A" is for active and "I" is for "Inactive".
When a program is in "Inactive" stage then you will see two entries in this table. One will have "A" and the other will have "I".
That's why in SE38 when you go by menu: Active <-> Inactive then it switches from "I" to "A".
Anyways you can develop a program which can update this table and Insert "I" for the program you have mentioned.
However I still don't think that just by making a program "Inactive" it will serve your purpose. Even if a program is "Inactive" but if it is syntactically correct then it will execute anyways.
Alternative is to use SM01 and Lock this transaction
Good Luck,
Neeraj
Edited by: Neeraj Singh on Feb 15, 2012 9:12 PM
‎2012 Feb 15 8:20 PM
Anyways you can develop a program which can update this table and Insert "I" for the program you have mentioned.
You must be kidding, right? Did you just suggest to update the SAP standard table directly?
‎2012 Feb 15 9:58 PM
No i am not advising to update the SAP tale directly. didn't realize that someone will pick it literally. The intent is just to indicate how it can be done. One will have to find out a way of how standard SAP fills that table. It involved some debugging.
‎2012 Feb 15 8:35 PM
Hi Zeran,
There is no direct way for this, but if you really wish to use this program for some cases and switch off for other you should better put a check, for example you can keep an entry in TVARVC table and in the start of this program you have to put a code which will check this entry.
Let's say your entry will be nothing but a flag. 'X'. So if flag is there program will execute otherwise it will not, this way you can activate deactivate just by changing the table entry, no help required from any ABAPer. (Ofcourse one time help is required to put this code in the program) after that it will work as a switch.
Best Regards,
Tapodipta Khan.