Xbasic

SQL::Connection::PrimaryKeyExpression Function

Syntax

Key_Expression as C = PrimaryKeyExpression(Table as C)

Arguments

Key_Expression

The expression that TableName uses to calculate primary index values.

SQL::Connection

A SQL::Connection object.

Table

The name of a table in the back-end database.

Description

Return the primary key expression for a Table.

Discussion

The PrimaryKeyExpression() method returns the primary key expression for a table.

Example

dim conn as SQL::Connection
dim connString as C
connString = "{A5API='Access', FileName='c:\program files\a5v8\mdbfiles\alphasports.mdb'}"
if .not. conn.open(connString)
    ui_msg_box("Error", conn.CallResult.text)
    end
end if
ui_msg_box("Primary Key Expression", conn.PrimaryKeyExpression("customer"))
conn.close()

See Also