The Query Builder allows you to quickly create filter and order expressions and apply them to a table or set. To use the Query Builder :
Display the Operations tab of the Control Panel.
Click New to display the Create New Operation dialog.
Choose "Query records" from the Select Operation list.
Pick the table or set from the Select Table/Set list.
On the Filter/Order Expression tab:
Optionally, enter an expression into the Filter Expression field. Click the 'xy' icon to use the Expression Builder to help you define the expression.
Optionally, enter an expression into the Order Expression field. Click the 'xy' icon to use the Expression Builder to help you define the expression.
Display the Query Options tab.
Optionally, check the Exclude records that satisfy search criteria to invert the logic of the query.
Optionally, check Unique records only to eliminate duplicate records.
Optionally, limit the records you retrieve by using a function in the Sub-select Options list.
If required, enter the value of N.
Click Run Query to filter and sort the records visible in your layout.
Click Close to exit from the Query Builder.
Click the 'circular arrow' icon to roll up the Query Builder.
Click the 'binoculars' icon to display the Filter/Order Expressions dialog box, which show Xbasic filter and order expressions you created in the Query Builder. This is an excellent way to learn or copy the syntax for creating filter and order expressions.
Click to switch from Genie Mode to Expression Mode. If you save the filter as an expression, you can no longer edit it using the Query Builder. Advanced users can use Expression Mode to type in additional filter and order expressions.
Click the 'floppy disk' icon to save the query for later re-use.
Click the following to save the query with a new name.
Click the 'open folder' icon to load a previously saved query.
Click the following to load create a new query.