This content has been translated automatically.  Click here  to view the French version.
Help / Tools / WDSQL
  • Overview
  • Creating a script
  • Creating a script from the main window of WDSQL
  • Creating a script for creating a new table in the current database
  • Running a script
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WindowsLinuxPHPWEBDEV - Browser code
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Stored procedures
A script is a set of SQL commands used to perform a specific operation (create a new table in the database, insert records, ...).
A script includes several lines. Each script line contains a SQL code that can be run independently.
A script must be run line by line, in Batch mode.
Remark: The following operations can only be performed on files accessed via an OLE DB provider, an ODBC driver or a native access:
  • Creating the structure of a file/table.
  • Modifying the structure of a file/table.
  • Deleting the structure of a file/table.
Creating a script
A script can be created:
  • fom the main window of WDSQL,
  • from the wizard for table creation (script for table creation).
  • To save a script, select "File .. Save a query" or click .
  • To print the SQL code of a script, select "File .. Print the source code of the query" or click .

Creating a script from the main window of WDSQL

WDSQL proposes several methods to help you create the script in SQL:
  • View and/or use existing fields in the current database: click . For more details, see Database structure.
  • View and/or use the various SQL keywords: click .
  • View the different types of variables supported by the current database: click .

Creating a script for creating a new table in the current database

To create a script for creating a new table in the current database:
  1. Select "File .. Create a query" (or click ). The wizard starts.
  2. Select "A script for creating a new table". Go to the next step.
  3. Type the name of the table to create ("Table name" option).
  4. For each table item:
    • Type the item name ("Control name" option).
    • Click the "Add" button.
    • Specify the type of item. The available types depend on the current database.
    • Specify the item size.
    • Specify whether the item must be indexed.
    • Specify whether the item can be null.
  5. Check (if necessary) "Generate the DROP TABLE command" to automatically generate the "DROP TABLE" command.
    Reminder: The DROP TABLE command is used to delete a table.
  6. Validate the wizard. The SQL code of the script for table creation is automatically displayed in the main window of WDSQL.
Running a script
To run a script:
  1. Load (if necessary) the script to run in WDSQL (select "File .. Load a query" or click ).
  2. Select "Execution .. Run a script in batch" (or click ).
Minimum version required
  • Version 9
This page is also available for…
Click [Add] to post a comment

Last update: 06/08/2023

Send a report | Local help