In our projects we generally create a custom variant for the code inspectors, which take cares of our project related Naming convention and coding standard.

If you are new in creating Code inspector variant you can refer below link.

http://wiki.scn.sap.com/wiki/display/ABAP/Creating+code+inspector+Check+Variant+for+client+specific+naming+conventions


In general whenever we develop any object or make any changes in any object, we go to Transaction SCII and run the code inspector for Z created Variant instead of directly checking it from Object menu Class/Program/Function module etc. ->Check -> code inspector.

Reason for the same is our Z created variant is not set as Default.


Once it is set as Default then you can use from object menu also.


Please follow below process to set the Z variant as default variant.


Go to T-code – SCI

  /wp-content/uploads/2015/06/1st_732098.jpg    

In Check variant write Z variant and then click on button on left side of Check variant /wp-content/uploads/2015/06/2nd_732099.png  and this will turn to /wp-content/uploads/2015/06/3rd_732100.jpg              making it global as generally Variant which we create is global.(If it is created as Local keep it as it is)


Click on copy button /wp-content/uploads/2015/06/4th_732104.jpg, POP up will occur, in new variant write DEFAULT and press enter it will automatically get associated with your code inspector.


/wp-content/uploads/2015/06/5th_732105.jpg



Now go to your program and run Code inspector



/wp-content/uploads/2015/06/6th_732111.jpg

You will now be able to able to see naming convention error and other project specific norm related error.

Note: When ever any alteration is been made in Z Variant we again have to assign it to our ID

To report this post you need to login first.

3 Comments

You must be Logged on to comment or reply to a post.

  1. Peter Inotai

    I would prefer to use ATC, because there you can set your own variant as default and the layout is much more user friendly.

    For code inspector there is also a table SCICHKV_ALTER for setting a new default variant in a safer way. To be honest I never tried myself, so I have no experience if it works.

    Peter

    (0) 

Leave a Reply