system.db
Database Functions
The following functions give you access to view and modify data in the database.
📄️ system.db.addDatasource
Adds a new database connection in Ignition.
📄️ system.db.beginTransaction
Begins a new database transaction.
📄️ system.db.clearAllNamedQueryCaches
This clears the caches of all Named Queries in a project.
📄️ system.db.clearNamedQueryCache.md
This clears the cache of a Named Query.
📄️ system.db.closeTransaction
Closes the transaction with the given ID.
📄️ system.db.commitTransaction
Performs a commit for the given transaction.
📄️ system.db.createSProcCall
Creates an SProcCall object, which is a stored procedure call context.
📄️ system.db.dateFormat
This function is used to format Dates nicely as strings.
📄️ system.db.execSProcCall
Executes a stored procedure call.
📄️ system.db.getConnectionInfo
Returns a dataset of information about a single database connection, as specified by the name argument.
📄️ system.db.getConnections
Returns a dataset of information about each configured database connection. Each row represents a single connection.
📄️ system.db.refresh
This function will programmatically cause a SQL Query or DB Browse property binding to execute immediately.
📄️ system.db.removeDatasource
Removes a database connection from Ignition.
📄️ system.db.rollbackTransaction
Performs a rollback on the given connection.
📄️ system.db.runNamedQuery
Runs a named query and returns the results.
📄️ system.db.runPrepQuery
Runs a prepared statement against the database, returning the results in a PyDataSet.
📄️ system.db.runPrepUpdate
Runs a prepared statement against the database, returning the number of rows that were affected.
📄️ system.db.runQuery
Runs a SQL query, usually a SELECT query, against a database, returning the results as a dataset.
📄️ system.db.runScalarPrepQuery
Runs a prepared statement against a database connection just like the runPrepQuery function, but only returns the value from the first row and column.
📄️ system.db.runScalarQuery
Runs a query against a database connection just like the runQuery function, but only returns the value from the first row and column.
📄️ system.db.runSFPrepUpdate
Runs a prepared statement query through the store and forward system and to multiple datasources at the same time.
📄️ system.db.runSFUpdateQuery
Runs a query through the store and forward system and to multiple datasources at the same time.
📄️ system.db.runUpdateQuery
Runs a query against a database connection, returning the number of rows affected.
📄️ system.db.setDatasourceConnectURL
Changes the connect URL for a given database connection.
📄️ system.db.setDatasourceEnabled
Enables/disables a given database connection.
📄️ system.db.setDatasourceMaxConnections
Sets the Max Active and Max Idle parameters of a given database connection.
Functions by Scope
- addDatasource
- beginTransaction
- clearAllNamedQueryCaches
- md
- closeTransaction
- commitTransaction
- createSProcCall
- dateFormat
- execSProcCall
- getConnectionInfo
- getConnections
- refresh
- removeDatasource
- rollbackTransaction
- runNamedQuery
- runPrepQuery
- runPrepUpdate
- runQuery
- runSFPrepUpdate
- runSFUpdateQuery
- runScalarPrepQuery
- runScalarQuery
- runUpdateQuery
- setDatasourceConnectURL
- setDatasourceEnabled
- setDatasourceMaxConnections
- addDatasource
- beginTransaction
- clearAllNamedQueryCaches
- md
- closeTransaction
- commitTransaction
- createSProcCall
- dateFormat
- execSProcCall
- getConnectionInfo
- getConnections
- refresh
- removeDatasource
- rollbackTransaction
- runNamedQuery
- runPrepQuery
- runPrepUpdate
- runQuery
- runSFPrepUpdate
- runSFUpdateQuery
- runScalarPrepQuery
- runScalarQuery
- runUpdateQuery
- setDatasourceConnectURL
- setDatasourceEnabled
- setDatasourceMaxConnections