Some tips on ABAP query (SQ01) Part 2
This is the sequel of the previous document I posted earlier.
Here I’m gonna explain some more tips about how to make your ABAP query to look more professional like a ABAP program report.
If you want to remove a table in the table join from infoset, you first need to delete it in the query.
Now on the selection screen if you want to change description of the fields, the order in which they appear, show hide intervals, etc you can do it in the query itself.
Below is an example
The selection screen changes like below:
Now you want to include your own conditions, rescrict the report to run only for certain values, hide fields, for that you just need to create a variant (shown above).
Now I create a variant with following conditions.
If you check the box Only display in catalog, users cannot see the variant, so they cannot change it themselves.
Now after the variant is applied,
Now you may want this report to start with this variant as default. So that users don’t have to input the values every time.
You’d have to assign the default variant in change query mode as shown below.
Your query is ready but it still not as user friendly as a program with transaction code so we assign the tcode to it.
Now click on the In background push button to know the program name of the query.
Go to SE93 and create a transaction of type report, assign the above program to the tcode.
Hi Jeevan,
Good informative document.
very good, especially for function consultant, hope share more in the future
Hi Jeevan,
Valuable reference.
Appreciating your contributions.
Useful contribution
helpful document Thanks Jeevan
Dear Jeevan,
Thank you for sharing this useful information.
Just wanted to know...
Is it possible to use an OR command in a query?
Taking a very basic eg.: If I need a list of materials with MRP controller "X" or MRP Type "Y"
I can build a query directly for table MARC but can i incorporate this OR condition??
(without having to write a code of course)
Hi Jeevan,
thats' good one,would pls help me in one more issue,
i want to split Time field in SQ01, How to do??
regards
Shoaib
Hello Every one,
I am getting issues like in SQ01 query chnages
* Output sequence of lines does not correspond to database structure
Line 01 (contains fields from table ANLB) cannot appear before
line 05 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 01 (contains fields from table ANLB) cannot appear before
line 06 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 02 (contains fields from table ANLCV) cannot appear before
line 05 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 02 (contains fields from table ANLCV) cannot appear before
line 06 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 03 (contains fields from table ANLCV) cannot appear before
line 05 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 03 (contains fields from table ANLCV) cannot appear before
line 06 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 04 (contains fields from table ANLCV) cannot appear before
line 05 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 04 (contains fields from table ANLCV) cannot appear before
line 06 (contains fields from table ANLAV)
any one can help me
Hello Every one,
I am getting issues like in SQ01 query chnages
* Output sequence of lines does not correspond to database structure
Line 01 (contains fields from table ANLB) cannot appear before
line 05 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 01 (contains fields from table ANLB) cannot appear before
line 06 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 02 (contains fields from table ANLCV) cannot appear before
line 05 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 02 (contains fields from table ANLCV) cannot appear before
line 06 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 03 (contains fields from table ANLCV) cannot appear before
line 05 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 03 (contains fields from table ANLCV) cannot appear before
line 06 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 04 (contains fields from table ANLCV) cannot appear before
line 05 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 04 (contains fields from table ANLCV) cannot appear before
line 06 (contains fields from table ANLAV)
any one can help me
Hello Every one,
I am getting issues like in SQ01 query chnages
* Output sequence of lines does not correspond to database structure
Line 01 (contains fields from table ANLB) cannot appear before
line 05 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 01 (contains fields from table ANLB) cannot appear before
line 06 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 02 (contains fields from table ANLCV) cannot appear before
line 05 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 02 (contains fields from table ANLCV) cannot appear before
line 06 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 03 (contains fields from table ANLCV) cannot appear before
line 05 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 03 (contains fields from table ANLCV) cannot appear before
line 06 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 04 (contains fields from table ANLCV) cannot appear before
line 05 (contains fields from table ANLAV)
* Output sequence of lines does not correspond to database structure
Line 04 (contains fields from table ANLCV) cannot appear before
line 06 (contains fields from table ANLAV)
any one can help me
Great work Jeevan!!!!!!!!!!!!
thanks for the guide
Thanks for sharing .
Hi Jeevan...
Thanks for your contribution towards framing such a wonderful document.
Regards,
J.Sakthikumar
Hi
Good post, but an additional comment. If the program AQ* is linked to a tcode in SE93, when you change something and transport the request from development to production, remember to generate again in SQ01 is you want the tcode trigger the modifications
Regards
Eduardo
Nice document. It helped me in deleting a field from Field group.
Thanks!!