‎2006 Oct 02 7:31 PM
I am new to ABAP programming. When I compile an INCLUDE program, sometimes I get the following message:
"REPORT/PROGRAM Statement Missing, or program type is I (INCLUDE)".
But sometimes, when I compile it acts just like a normal program and gives either a regular compilation error or "The program is syntactically correct" message.
I am not able to understand, when do I get which one. Please help.
‎2006 Oct 02 7:33 PM
Hello Raju,
U should not compile Include program(type I). But you can compile with the combination of executable program(Type 1) at a time.
I hope you are cmpiling Include without the main program..thats the reason sometimes you are getting the other error. So try to execute with the main program.
Reward the helpful answers
Thanks
Eswar
‎2006 Oct 02 7:33 PM
Hi,
If you are in an include always do CTRL + F7 which means checking the main program..
That way all the includes in the main program will be compiled..If there is no syntax errors then actiavate the programs (CTRL + F3)..
Thanks,
Naren
‎2006 Oct 02 7:33 PM
Hello Raju,
U should not compile Include program(type I). But you can compile with the combination of executable program(Type 1) at a time.
I hope you are cmpiling Include without the main program..thats the reason sometimes you are getting the other error. So try to execute with the main program.
Reward the helpful answers
Thanks
Eswar
‎2006 Oct 02 7:34 PM
Hi Raju,
Welcome to SDN.
The best is always go to main program to compile the include changes.
Regards,
Ferry Lianto
‎2006 Oct 02 7:52 PM
Many thanks for all the replies. May be I should have given this info also; did n't think it was necessary. The INCLUDEs that I am coding are part of a BW ODS object start routine. So, when I compile the start routine, (Which is the main program), if there is an error in one of the INCLUDEs, then it simply says ... "The include xxx not found". Also sometimes these INCLUDES can get really big. So, I would like to compile them individually for sytax check. And like I had mentioned, I was able to do it. I am wondering, if there is a setting, that I am missing,that will let me do this.
‎2006 Oct 02 7:57 PM
Hi Raju,
In Debugging you can clearly point out in which INCLUDE its giving error.
We can not compile the includes separately.
Regards,
Azaz.
‎2006 Oct 03 2:56 PM
I may sound stubborn. But (I swear!) I was able to do the compilations of INCLUDE programs indivudually, where it used to give messages like "program sytactically correct". And I am not able to do it today. I do not know what I am doing different this time.
Also, when I try to compile the INLCUDE, I get a message at the bottom saying "There is no main program for INCLUDE xxx".
‎2006 Oct 03 3:00 PM
I believe that if you hit the Check button (CtrlF2) you will get the 'Report is an Include' message. If you hit the activate button (CtrlF3) it will compile and activate with a 'Success' type message.
‎2006 Oct 03 6:37 PM
Activate simply says "Object(s) Activated". It does not give "Program Syntactically Correct".
‎2006 Oct 03 6:50 PM
You can always do a Syntax check on an INCLUDE Program. To quote SAP help, such a check does not normally ensure that statements of your include program fit logically into the source code of the programs from which it is called. For the syntax check to produce valid results, you must check the program in which the include occurs.
~Suresh
‎2006 Oct 03 8:20 PM
Hi Suresh,
You had mentioned, "You can always do a Syntax check on an INCLUDE Program. "
Can you please tell me, how do I do that?
I understand your point that, even if the INCLUDE is syntactically right, it may not be right logically.
‎2006 Oct 02 7:50 PM
Hi Raju,
Go through this link,
http://help.sap.com/saphelp_47x200/helpdata/en/9f/db973535c111d1829f0000e829fbfe/frameset.htm
Regards,
Azaz.
‎2006 Oct 03 8:28 PM
Hi
You should not compile the include programs..
bcoz there are not complete by itself...
Cheers,
Abdul Hakim
Mark all useful answers...
‎2006 Oct 03 11:33 PM
Hi Raju,
If you are only trying to check the syntax of the include you could even check it with the Ctrl+F3
which would anyways check the sytax of the code and if it's is right it would activate the code.
Cheers
‎2006 Oct 04 6:25 PM
Iam not sure, if one or all of you are saying this. But here is what I had figured out. My main program is actually generated by BW, using the start routine. Sometimes, for some reason (which I need to investigate) that main program is disappearing. In these instances, when I try to compile the INCLUDE, I am egtting the warning that I was mentioned about. It gives me this warning, even if there are syntax errors. But when I compile the INCLUDE, with the this main program existing, I get either syntax errors or the message "program syntactically correct". So, it seems to boil down to whether this INLCUDE is part of a MAIN program or not. And I seem to be able to compile my INCLUDE individually, only when it's part of a main program.