Do you have any question about this error?
Message type: E = Error
Message class: AQ - Message texts for SAP Query
Message number: 221
Message text: Query & can only be started using a variant
To execute this query, you must always specify a variant. You can do
this only on the initial screen.
The system issues an error message and will not allow you to continue with this transaction until the error is resolved.
Specify a variant on the initial screen of the component <LS>Maintain
Queries</> screen.
If you are not on the initial screen, you cannot execute the query
directly. You must always return to the initial screen first.
Error message extract from SAP system. Copyright SAP SE.
AQ221
- Query & can only be started using a variant ?The SAP error message AQ221 indicates that a query can only be executed using a variant. This typically occurs in the context of SAP Query or SAP Report transactions where a specific variant (a predefined set of parameters) is required to run the query.
Cause:
- Missing Variant: The query you are trying to execute has been configured to require a variant, and you have not selected one.
- Query Configuration: The query may have been set up in such a way that it mandates the use of a variant for execution, possibly due to specific selection criteria or parameters that need to be predefined.
- User Permissions: In some cases, user permissions or roles may restrict the ability to run queries without a variant.
Solution:
Select a Variant:
- When you attempt to run the query, look for an option to select a variant. This is usually available in the selection screen of the query.
- If you do not have any variants created, you may need to create one by entering the desired selection criteria and saving it as a variant.
Create a Variant:
- Go to the selection screen of the query.
- Enter the required parameters for the query.
- Click on the "Save as Variant" button (often represented by a disk icon or similar).
- Provide a name and description for the variant and save it.
- After creating the variant, you can select it to run the query.
Check Query Settings: If you have access, review the query settings to see if it can be modified to allow execution without a variant. This may require administrative privileges.
User Roles and Permissions: Ensure that your user role has the necessary permissions to execute queries and manage variants.
Related Information:
SQ01
(SAP Query) and SQ02
(InfoSet) for creating and managing queries and variants.By following these steps, you should be able to resolve the AQ221 error and successfully execute your query using a variant.
Get instant SAP help. Start your 7-day free trial now.
AQ220
Specify a variant name
What causes this issue? You selected the <LS>Execute with variant</> function. This requires you to specify the name of a variant. You ca...
AQ219
The output length must be greater than zero
Self-Explanatory Message Since SAP believes that this specific error message is 'self-explanatory,' no more information has been given.The majority of...
AQ222
Standard variant & does not exist
What causes this issue? When you execute this query, the system is always supposed to use the (standard) variant specified in the message, unless you...
AQ223
Variant & does not exist
Self-Explanatory Message Since SAP believes that this specific error message is 'self-explanatory,' no more information has been given.The majority of...
Click on this link to search all SAP messages.