DatabaseLink`
DatabaseLink`
SQLTable
SQLTable[…]
represents a table in an SQL connection.
更多信息和选项
- To use SQLTable, you first need to load DatabaseLink using Needs["DatabaseLink`"].
- The following option can be given:
-
"TableType" "TABLE" type of table
范例
基本范例 (1)
Needs["DatabaseLink`"]If you find that the examples in this section do not work as shown, you may need to install or restore the example database with the DatabaseLink`DatabaseExamples` package, as described in Using the Example Databases.
conn = OpenSQLConnection["demo"];List the tables in a connection:
SQLTables[conn]Specify a table in a prepared statement:
SQLExecute[conn, "SELECT `1` FROM `2`", {SQLColumn["VALUE"], SQLTable["SAMPLETABLE1"]}]CloseSQLConnection[conn];