You can use a plain text file to store a SQL statement and then op the file in Topaz to allow Topaz to execute the SQL.
E.g.
- Code: Select all
Select A."Number", A."Person" from Master A where A.Person <> ''
Steps to open an SQL:
- Open Topaz
- Click on the "Query" button on the bottom left
- Click the "Open Query" button at the top of Topaz
- Use the small window that pops up to browse to the location of the SQL file that you saved. If you don't see you file, click the "Fiels of type" dropdown at the bottom of the window and select "All Files". Now the window should display all files in the location.
- Select your file and click "open"
- If the SQL statement was anything other than a "SELECT" statement, you will get a error popup "Error Creating Cursor Handle". You can ignore that error. Any other error means that you have an SQL syntax error and that should be fixed int he SQL file.
- If you used a "SELECT" statement, the resulting information will be displayed in the grid on the Query screen.
Data that is displayed in the Query screen, can be exported, by right-clicking on the grid and selecting to export the data to a file.
Please ensure that the SQL is correct as incorrect SQLs can damage the data in your database. Datatex cannot be held responsible to the incorrect use of this facility.