Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
programs:odxsql:home [2010/07/03 23:13]
tdo
programs:odxsql:home [2012/10/26 14:51] (current)
Line 3: Line 3:
 ~~NOTOC~~ ~~NOTOC~~
 ====== OdxSQL Quick Reference ====== ====== OdxSQL Quick Reference ======
-{{page>:odxsql_bar&​nofooter&​noeditbtn}}+{{page>:sql_odxsql_bar&​nofooter&​noeditbtn}}
 ^ Command Line Options ^ Description ^ ^ Command Line Options ^ Description ^
 | odxsql | Run OdxSQL. ​ Use the CONNECT command to connect to an Omnidex Environment | | odxsql | Run OdxSQL. ​ Use the CONNECT command to connect to an Omnidex Environment |
 | odxsql env_filespec | Run OdxSQL and connect to the env_filespec. | | odxsql env_filespec | Run OdxSQL and connect to the env_filespec. |
-| odxsql dsn_filespec -odxnet -odbc | Run OdxSQL and an OdxNET ​background process and connect to the ODBC File DSN using ODBC |+| odxsql dsn_filespec ​-odbc |Run OdxSQL and connect to the ODBC File DSN using the Omnidex ODBC driver.| 
 +| odxsql env_filespec ​-odxnet -jdbc |Run OdxSQL and start an OdxNet ​background process and connect to the env_filespec ​using the Omnidex JDBC driver.|
 | odxsql -? | Displays OdxSQL command line options | | odxsql -? | Displays OdxSQL command line options |
 | odxsql -use scriptfile | Run OdxSQL and read and process the scriptfile of OdxSQL Statements and Commands.| | odxsql -use scriptfile | Run OdxSQL and read and process the scriptfile of OdxSQL Statements and Commands.|
-^Set Command ^Description ​^+^Set Command ^ ^
 |SET| Shows the current settings. | |SET| Shows the current settings. |
 |SET ? | Shows the list of available SET options. | |SET ? | Shows the list of available SET options. |
-|SET TERMINATION OFF|Will ​Automatically terminate ​SQL Statements.| +|SET TERMINATION OFF|Will ​process ​SQL Statements ​without requiring a semi-colon terminator.| 
- +|SET TIMER ON|Useful to show how long a statement takes to process.| 
-^ Help/Show ^Description^+^ Help/Show ^ ^
 |HELP|Shows a list of OdxSQL commands and SQL Statements.| |HELP|Shows a list of OdxSQL commands and SQL Statements.|
-|HELP <COMMAND>​|Provides specific help on the specified command or SQL Statement.|+|HELP <command>​|Provides specific help on the specified command or SQL Statement.|
 |SHOW <​table>​|Provides information on the specified table.| |SHOW <​table>​|Provides information on the specified table.|
 |SHOW ALL|Provides information on all tables.| |SHOW ALL|Provides information on all tables.|
 +^Editing^ ^
 +|EDIT| Launch editor and send current SQL Statement to either Windows Notedpad or UNIX/Linux vi or emacs. |
 +|SET EDITOR <​filespec>​|Change the default editor. Can also be NOTEPAD, WORDPAD, VI or EMACS.|
 +|EDIT filespec|Typically used to edit a script file and then use the USE file to run the script.|
 +|EDIT n|Edits the command in the Command History Stack|.
 +^Other Commands^ ^
 +|HISTORY|Shows a numbered list of previously entered commands.|
 +|<​command_number>​|Execute the numbered command from the Command History Stack.|
 +|Period (.)|Execute the last command.|
 +|Comment (;) | A semi-colon as the first character causes the rest of the line to be a comment. |
 +|USE <​filespec>​|Processes the OdxSQL commands in a script file.|
 +|SET ERRORS | Sets how errors will be handled when processing a USE file. |
 +|EXPLAIN|Shows the Explain Plan for the previous SELECT Statement.|
 +|SET AUTOEXPLAIN ON|Automatically show the Explain Plan instead of the SELECT output.|
 +|SET EXPLAIN |Sets options for the Explain Plan. |
  
 +^ OdxSQL Settings ^ ^ ^ ^ ^ ^
 +|API |AUTODISPLAY |AUTOEXPLAIN |AUTOFETCH |AUTOPSEUDOCOLUMNS |AUTORECONNECT|
 +|AUTOSUBPROCESS|CHAR|CURSOR|CURSORDISPLAY|DEFAULTS|EDITOR|
 +|ENDIAN |ERRORDISPLAY|ERRORS|EXPLAIN SET|FILE_BASELINE|HEADERS|
 +|HEX|HISTORY|INTERRUPTS|MEMORY_BASELINE|MULTICONNECT|MULTILINE|
 +|NULL_INDICATORS|OMNIDEX_DEBUG|OPTIMIZATION|ODXSQL_DEBUG|PAGELENGTH|PAGEWIDTH|
 +|PREPROCESSOR|PROGRESS|PROMPT|PSEUDOCOLUMNS|QUALIFY_COUNTS|REDEFROWIDS|
 +|REQUIRED_OPTIMIZATION|SILENT_MODE|SQL_LOGFILE|SQL_LOGGING|SQL_SYNTAX|STATISTICS|
 +|STATISTICS_COMMENT|STATUSDISPLAY|TERMINATION|TIMEOUT|TIMER|
  
-===== OdxSQL Uses ===== 
- 
-OdxSQL is a console application for manually entering Omnidex SQL Statements and OdxSQL Commands or for processing scripts of Omnidex SQL statements. 
- 
-Use OdxSQL for processing Omnidex SQL Data Definition Scripts to create Omnidex Environments and Indexes. 
- 
-Use OdxSQL to test Omnidex SQL SELECTs and ODBC, JDBC and Network Services set up. 
- 
-Use OdxSQL to prototype Omnidex Queries and use the Explain Command to review optimization. 
- 
-Use OdxSQL on a client computer to access an Omnidex Environment on a remote server via OdxNet to test network response times. 
- 
-  
-===== Common ways to run OdxSQL ===== 
- 
- 
-  os> odxsql 
-  os> odxsql envfile 
-  os> odxsql dsnfile -odxnet -odbc 
-  os> odxsql -? 
-  os> odxsql -use scriptfile 
- 
-Running OdxSQL Explained: ​ 
-| odxsql | Run OdxSQL. ​ Use the CONNECT command to connect to an Omnidex Environment | 
-| odxsql envfile | Run OdxSQL and connect to the '​envfile'​ | 
-| odxsql dsnfile -odxnet -odbc | Run OdxSQL and an OdxNET background process and connect to the DSN using ODBC | 
-| odxsql -? | Displays OdxSQL command line options | 
-| odxsql -use scriptfile | Run OdxSQL and read and process the scriptfile of OdxSQL Statements and Commands.| 
- 
- 
-===== OdxSQL Important Information ===== 
- 
-  * OdxSQL connects to an Omnidex Environment or ODBC or JDBC Omnidex File Datasource (DSN). 
-    * connect myenv.xml 
-    * connect mydsn.dsn using odbc  (needs OdxNet running) 
-    * connect mydsn.dsn using jdbc  (needs OdxNet running) 
- 
-    * OdxSQL requires a semicolon terminator for SQL Statements and will prompt for additional statement information until a semicolon is found. 
-    * Use SET TERMINATION OFF and OdxSQL will not required the semicolon termination character and will end the statement automatically. 
-    * With SET TERMINATION OFF, use the backslash %%[ \ ]%% statement continuation character for multi line statements. ​ 
-    * Use HELP <cr> to display a list of commands and SQL Statements. 
-    * Use HELP <​command>​ to display the syntax for the command. 
- 
-  
-  * Use SHOW <​table>​ to show information on a table with the tables'​s column layout. 
-    * Use SHOW ALL to see all tables, including internal system tables. 
- 
-  * Create scripts with an editor and process with the USE <​scriptfile>​ command or the OdxSQL -use scriptfile 
-    ​ 
-  * Use EDIT to edit the last statement using Windows Notepad or Linux/Unix vi or emacs. 
-    * Use SET EDIT to change the editor of choice. 
-    * Use EDIT file to edit a script file without leaving OdxSQL and then USE file to run. 
-    * Use EDIT n to edit a command in the Command History Stack. 
- 
-  * Edit previous commands by using the UP ARROW and scrolling through the commands. 
-    * Use the Right and Left Arrow, Insert, Delete, Home, and End keys to edit. 
- 
-  * Use HISTORY to display a numbered list of previous commands. 
-    * Use the history number to re-execute the numbered command. 
-    * Use a period ( . ) to execute the last command. 
-  
- 
-===== See Also ===== 
- 
-    * [[programs:​odxsql:​overview | OdxSQL Overview ]] 
-    * [[programs:​odxsql:​commands:​home |OdxSQL Commands ]] 
-    * [[programs:​odxsql:​settings:​home |OdxSQL Settings ]] 
-    * [[programs:​odxsql:​commandline |OdxSQL Command Line Options ]] 
-    * OdxSQL Script Examples 
-    * [[ dev:​sql:​statements:​select:​home | SQL SELECT ]] 
-    * SQL SELECT Examples 
-    * [[ dev:​sql:​statements:​home | Omnidex SQL Statements ]] 
- 
-===== OdxSQL Internal SET Commands ===== 
- 
-<​code>​ 
-Internal 
-x [AUTOPSEUDOCOLUMNS <ON | OFF>] 
-x [AUTORECONNECT <ON | OFF>] 
-x [AUTOSUBPROCESS <n | NONE> 
-x [STATISTICS_COMMENT "​string"​] 
-x [PREPROCESSOR <ON | OFF>] 
-x [PROGRESS <ON | OFF>] 
-x [MEMORY_BASELINE] 
-x [FILE_BASELINE] 
-</​code>​ 
- 
-===== Level 2 Headline ===== 
- 
-<​code>​ 
-        SET DEBUG … 
- SET OPTIMIZATION … 
- SET REQUIRED_OPTIMIZATION 
- SET CHAR … 
- SET TIMEOUT … 
- SET REDEFROWIDS …  
- SET PSEUDOCOLUMNS … 
- SET QUALIFY_MODE <ODXFIND | PARSER > 
- SET AUTOPSEUDOCOLUMNS … 
- SET PREPROCESSOR … 
- SET SQL_LOGGING … 
- SET SQL_LOGFILE … 
-</​code>​ 
- 
- 
-The syntaxes of the SQL Logging SET commands are shown below: 
- 
-    set sql_logging <on | off> ​ 
- 
-This command activates SQL Logging for this process. ​ By default, statements are logged to the $SQL_STATEMENTS file along with statistics about the execution of the command. ​ The $SQL_STATEMENTS file is named “sqllog.tdf”,​ and is located in the same directory as the compiled environment file.  This file is a standard tab-delimited file, and may be easily imported into other applications. ​ The file may be flushed by simply removing the file; the file will be automatically recreated the next time logging is activated. 
- 
-    set sql_logfile <​filename>​ 
- 
-This command redirects the SQL logging for this process to a text file that only contains the statement, and does not contain any statistical information. ​ If the file already exists, it will be appended to rather than overwritten. 
- 
- 
- 
-{{page>:​bottom_add&​nofooter&​noeditbtn}} 
 
Back to top
programs/odxsql/home.1278198828.txt.gz · Last modified: 2012/10/26 14:48 (external edit)