Database[SQLite] - Maple Programming Help

Online Help

All Products    Maple    MapleSim


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

Database[SQLite]

  

ClearBindings

  

prepare SQL statement

 

Calling Sequence

Parameters

Description

Examples

Compatibility

Calling Sequence

ClearBindings( statement )

Parameters

statement

-

prepared statement obtained using Prepare command

Description

• 

The ClearBindings command resets value bindings for parameters un prepared SQL statement.

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:

Execute statement again without clearing - the "value 1" is inserted

Resetstmt

Stepstmt:

Resetstmt

Clear bound value and bind a new one

ClearBindingsstmt

Bindstmt,1,value 2

Stepstmt:

Finalizestmt:

stmtPrepareconnection,SELECT * FROM test

stmtSQLite statement,SELECT * FROM test

(2)

FetchAllstmt

value 1value 1value 2

(3)

Finalizestmt:

Closeconnection:

Compatibility

• 

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

• 

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

See Also

Database[SQLite][Bind]

Database[SQLite][Reset]