Tclodbc 2.1 Utility Procedure Reference

ColTypes DumpSchema DumpTable FieldFormat Justification LoadSchema LoadSql LoadTable SqlDelete SqlInsert SqlSelect SqlShell SqlTimeToTclTime SqlUpdate TableDef TableDefToSql TclTimeToSqlTime TkTableInit TkTableRead


ColTypes

Return list of column types for given columns. This list can be used as statement argument specification.

Parameters

DumpSchema

Dumps whole database schema to a named file.

Parameters

DumpTable

Dump the contents of a named table to a file. The filename may be given explicitly, but if not, a default name of the form $tablename.d is used.

The .d file format is the following: 1st line contains the data column names. from 2rd line forward, the data in tcl list format.

Parameters

FieldFormat

Formats given list of fields for output

Parameters

Justification

Returns default justification of a column, right, left or center

Parameters

LoadSchema

Loads whole database schema from a named file.

Parameters

LoadSql

Loads sql from a file to a database. The input file should contain one sql statement per line.

Parameters

LoadTable

Loads the contents of a named table from a file. The filename may be given explicitly, but if not, a default name of the form $tablename.d is used. The file format is assumed to be of the form generated by DumpData procedure, described above.

Parameters

SqlDelete

Create command for creating a delete statement for given table and columns.

Parameters

SqlInsert

Return command for creating a insert statement for given table and columns. Mode determines the action for the command. Useful modes are e.g. eval, return and puts.

Parameters

SqlSelect

Return command for creating a select statement for given table and columns. Mode determines the action for the command. Useful modes are e.g. eval, return and puts.

Parameters

SqlShell

Very simple sql shell. Execute given statements and return data in columnar format.

Parameters

SqlTimeToTclTime

Returns tcl time in seconds

Parameters

SqlUpdate

Return command for creating a update statement for given table and columns. Mode determines the action for the command. Useful modes are e.g. eval, return and puts.

Parameters

TableDef

Return the definition of a named database table. The definition consist of a list {tablename coldefs indexdefs}

Parameters

TableDefToSql

Transforms a TableDef as returned by procedure TableDef to a list of driver specific sql data definition statements.

Parameters

TclTimeToSqlTime

Returns sql timestamp of the form YYYY-MM-DD HH:MM:SS

Parameters

TkTableInit

Initialize tk table widget for a given result set

Parameters

TkTableRead

Display whole result set in a tk table widget. The statement object should be executed before calling this

Parameters