The SQL Select statement defines which tables and fields are used for the result screen. These are the important requirements:

Put the SQL statement in a file with SQL extension in the Search subfolder. This SQL can be edited in SQL Server Management Studio and test run there.

@txempl can be used as a placeholder for currently logged in user. To still enable testing with SQL Server add the following text before SELECT statement:
 
declare @txempl char(12)
set @txempl = 'XXX'
/*runtime*/

Where XXX is a test employee code. All text before /*runtime*/ will be disregarded at runtime.

If using a case sensitive database use all upper case on field names.

Only use one SQL Select statement. Semicolon (;) is not allowed.

We recommend having TOP 1000 after the select to limit the records if there could be a large amount of records returned

1=1 is a placeholder for the filter statement returned from the Filter UI.

2=2 can be used as a placeholder for an assigned to job filter that will only be applied if current user is not allowed to see all jobs. Normally a user will only see jobs he/she is assigned to.