2009 Jan 09 9:40 AM
I am passing certain code in table itab and then doing a syntax check using SYNTAX-CHECK FOR itab MESSAGE mess LINE lin WORD wrd .The problem with this method is it check the code line by line and assign mess with the first error msg but I want to trap all the error message of the code in itab at once in another table.
Is it possible to trap all the error msg at once in a internal table.
2009 Jan 09 12:16 PM
Do not post Duplicate Threads!!!
Against Forum rules.
regards,
neha
I am passing certain code in table itab and then doing a syntax check using SYNTAX-CHECK FOR itab MESSAGE mess LINE lin WORD wrd .The problem with this method is it check the code line by line and assign mess with the first error msg but I want to trap all the error message of the code in itab at once in another table.
Is it possible to trap all the error msg at once in a internal table.
2009 Jan 09 11:54 AM
it may not be logical to check syntax before fixing the first err.
2009 Jan 09 12:16 PM
Do not post Duplicate Threads!!!
Against Forum rules.
regards,
neha
2009 Jan 09 12:23 PM
Hi,
This is similar to what ABAP Editor sytax check does. You cannot check sytax of the "futher" code as the "closer" code may affect the "further". Unless you correct the first error you cannot therefore check if futher lines are correct. If this worked like you want it would have to correct "closer" errors first by itself, then it could check rest of the code. But how the compilator (generall meaning) would have to know what to place there. This is of course impossible. There is no such compliator doing so in none of known to me programming languages.
You may skip this by a trick. Looping at the table with a code and checking each line of this with a check syntax. Then collect all these errors within an error table.
Nevetherless be carefull !! You would have to place excatly one statement per line in code table. Otherwise it won't pass the exam. Moreover you cannot use any of chain statements i.e.
write: 'first line',
'second line'.
...should be replaced with
write 'first line'.
write 'second line'.
Hope this give you some idea:)
Regards
Marcin
2009 Jan 09 12:27 PM
hi
there are various ways of doing that
1. Static compilation - for syntax errors check.
2. Extended program check (transaction SLIN) - to analyze the errors, warnings and potential sources of runtime errors and others severe problems that may exist in your code.
3. Code Inspector (transaction SCI) - to perform more sophisticated static checks.
4. ABAP Unit testing - to ensure all modularization units of your program are actually doing what they are supposed to do.
5. Integration tests with eCATT, the extented Computer Aided Test Tool (transaction SECATT) - to verify that the modularization units and application screens work together correctly in a complex application scenario.
6. Coverage analysis (transaction SCOV) - to verify that all relevant parts of your program have been executed and tested before you release it for use in your production system.
hope this helps
regards
Aakash Banga
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |