Database[SQLite] - Maple Programming Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Connectivity : Database Package : SQLite : Database/SQLite/Bind

Database[SQLite]

  

Bind

  

bind value to a parameter in prepared statement

 

Calling Sequence

Parameters

Description

Examples

Compatibility

Calling Sequence

Bind( statement, parameter, value, valuetype )

Parameters

statement

-

prepared statement obtained using Prepare command

Description

• 

The Bind command resets value bindings for parameters in prepared SQL statement.

• 

parameter is the index of the SQL parameter to be set. The leftmost SQL parameter has an index of 1.

• 

See the Database[SQLite] for more information about type conversion between SQLite and Maple.

Examples

withDatabaseSQLite:

connectionOpen:memory::

Executeconnection,CREATE TABLE test (val):

stmtPrepareconnection,INSERT INTO test VALUES (?)

stmtSQLite statement,INSERT INTO test VALUES (?)

(1)

Bindstmt,1,value 1

Stepstmt:

Finalizestmt:

stmtPrepareconnection,SELECT * FROM test

stmtSQLite statement,SELECT * FROM test

(2)

FetchAllstmt

value 1

(3)

Finalizestmt:

Closeconnection:

Compatibility

• 

The Database[SQLite][Bind] command was introduced in Maple 18.

• 

For more information on Maple 18 changes, see Updates in Maple 18.

See Also

Database[SQLite][ClearBindings]