Home › Discussions › Questions & Answers › Implementing Either/Or Parameter Validation
Implementing Either/Or Parameter Validation
Customer · · Questions & Answers · 9 replies
For security and performance reasons, we must ensure that users running our Customer Account report provide *either* the ‘Customer Name’ OR the ‘Account Number’, but not necessarily both. How can I enforce this complex validation rule before the report even executes?
9 replies
You can enforce this ‘either-or’ logic using the Advanced Required Parameters feature . By clicking the ‘Required’ button on the Blitz Report Setup screen, you can define a custom logical expression . For your requirement, the expression would be written as a standard SQL logical phrase: `:Customer_Name is not null or :Account_Number is not null` . Blitz Report evaluates this expression at run-time, and if the condition is not met, the report submission is blocked .
What is the specific syntax for referencing parameters within the advanced logical expression, especially if they have spaces or special characters in their name?
In the advanced logical expression, parameters must be referenced by their name (in the installed base language, usually US), prefixed with a colon (`:`) . Any spaces or other non-word characters within the parameter name must be replaced with a single underscore (`_`) . For instance, ‘Customer Name’ becomes `:Customer_Name` .
If the validation fails, what error message is displayed to the user, and can I customize this message?
If the logical expression is not met, Blitz Report displays a default error message . For expressions enforcing at least one parameter entry (like your ‘either-or’ scenario), the default message text is stored in the FND message `XXEN_REPORT_ONE_PARAM_REQUIRED` . You can customize the displayed error message by entering your preferred text directly into the required message field when defining the logical expression .
Is it possible to define multiple different advanced logical expressions for a single report to handle different scenarios?
No, only one advanced logical expression can be set up per report . Once an advanced expression is defined, the standard ‘Required’ checkbox becomes visually labeled as ‘Advanced’ to indicate that a complex validation rule is in effect . This single expression must encompass all necessary validation logic for that report.
If I need to update this logical expression later, where is the most straightforward place to manage it?
The advanced required parameter logic is managed directly within the Blitz Report Setup form, accessible via the ‘Setup’ button on the run window, provided your user profile is set to ‘Developer’ or ‘System’ access . You access this through the ‘Required’ button (which changes to ‘Advanced’ once configured) within the parameter definition section of the report .
- You must be logged in to reply to this post.
Sign in with LinkedIn or Google to take part.