JDatabaseSQLSrv: Difference between revisions
From Joomla! Documentation
m →User contributed notes: moving preparation |
m moving preparation |
||
| Line 14: | Line 14: | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::__destruct | |[[API17:JDatabaseSQLSrv::__destruct|__destruct]] | ||
|Destructor. | |Destructor. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::connected | |[[API17:JDatabaseSQLSrv::connected|connected]] | ||
|Determines if the connection to the server is active. | |Determines if the connection to the server is active. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::dateToString | |[[API17:JDatabaseSQLSrv::dateToString|dateToString]] | ||
|Method to get a object represented as a datetime string in a format recognized by the database server. | |Method to get a object represented as a datetime string in a format recognized by the database server. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::explain | |[[API17:JDatabaseSQLSrv::explain|explain]] | ||
|Diagnostic method to return explain information for a query. | |Diagnostic method to return explain information for a query. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::getAffectedRows | |[[API17:JDatabaseSQLSrv::getAffectedRows|getAffectedRows]] | ||
|Get the number of affected rows for the previous executed SQL statement. | |Get the number of affected rows for the previous executed SQL statement. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::getCollation | |[[API17:JDatabaseSQLSrv::getCollation|getCollation]] | ||
|Method to get the database collation in use by sampling a text field of a table in the database. | |Method to get the database collation in use by sampling a text field of a table in the database. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::getEscaped | |[[API17:JDatabaseSQLSrv::getEscaped|getEscaped]] | ||
|Method to escape a string for usage in an SQL statement. | |Method to escape a string for usage in an SQL statement. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::getExporter | |[[API17:JDatabaseSQLSrv::getExporter|getExporter]] | ||
|Gets an exporter class object. | |Gets an exporter class object. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::getImporter | |[[API17:JDatabaseSQLSrv::getImporter|getImporter]] | ||
|Gets an importer class object. | |Gets an importer class object. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::getNumRows | |[[API17:JDatabaseSQLSrv::getNumRows|getNumRows]] | ||
|Get the number of returned rows for the previous executed SQL statement. | |Get the number of returned rows for the previous executed SQL statement. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::getQuery | |[[API17:JDatabaseSQLSrv::getQuery|getQuery]] | ||
|Get the current or query, or new object. | |Get the current or query, or new object. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::getTableCreate | |[[API17:JDatabaseSQLSrv::getTableCreate|getTableCreate]] | ||
|Shows the table CREATE statement that creates the given tables. | |Shows the table CREATE statement that creates the given tables. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::getTableFields | |[[API17:JDatabaseSQLSrv::getTableFields|getTableFields]] | ||
|Retrieves field information about the given tables. | |Retrieves field information about the given tables. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::getTableList | |[[API17:JDatabaseSQLSrv::getTableList|getTableList]] | ||
|Method to get an array of all tables in the database. | |Method to get an array of all tables in the database. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::getVersion | |[[API17:JDatabaseSQLSrv::getVersion|getVersion]] | ||
|Get the version of the database connector. | |Get the version of the database connector. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::hasUTF | |[[API17:JDatabaseSQLSrv::hasUTF|hasUTF]] | ||
|Determines if the database engine supports UTF-8 character encoding. | |Determines if the database engine supports UTF-8 character encoding. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::insertid | |[[API17:JDatabaseSQLSrv::insertid|insertid]] | ||
|Method to get the auto-incremented value from the last INSERT statement. | |Method to get the auto-incremented value from the last INSERT statement. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::query | |[[API17:JDatabaseSQLSrv::query|query]] | ||
|Execute the SQL statement. | |Execute the SQL statement. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::queryBatch | |[[API17:JDatabaseSQLSrv::queryBatch|queryBatch]] | ||
|Execute a query batch. | |Execute a query batch. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::select | |[[API17:JDatabaseSQLSrv::select|select]] | ||
|Select a database for use. | |Select a database for use. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::setUTF | |[[API17:JDatabaseSQLSrv::setUTF|setUTF]] | ||
|Set the connection to use UTF-8 character encoding. | |Set the connection to use UTF-8 character encoding. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::transactionCommit | |[[API17:JDatabaseSQLSrv::transactionCommit|transactionCommit]] | ||
|Method to commit a transaction. | |Method to commit a transaction. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::transactionRollback | |[[API17:JDatabaseSQLSrv::transactionRollback|transactionRollback]] | ||
|Method to roll back a transaction. | |Method to roll back a transaction. | ||
|- | |- | ||
|public | |public | ||
|[[JDatabaseSQLSrv::transactionStart | |[[API17:JDatabaseSQLSrv::transactionStart|transactionStart]] | ||
|Method to initialize a transaction. | |Method to initialize a transaction. | ||
|- | |- | ||
|public static | |public static | ||
|[[JDatabaseSQLSrv::test | |[[API17:JDatabaseSQLSrv::test|test]] | ||
|Test to see if the SQLSRV connector is available. | |Test to see if the SQLSRV connector is available. | ||
|- | |- | ||
|protected | |protected | ||
|[[JDatabaseSQLSrv::__construct | |[[API17:JDatabaseSQLSrv::__construct|__construct]] | ||
|Constructor. | |Constructor. | ||
|- | |- | ||
|protected | |protected | ||
|[[JDatabaseSQLSrv::fetchArray | |[[API17:JDatabaseSQLSrv::fetchArray|fetchArray]] | ||
|Method to fetch a row from the result set cursor as an array. | |Method to fetch a row from the result set cursor as an array. | ||
|- | |- | ||
|protected | |protected | ||
|[[JDatabaseSQLSrv::fetchAssoc | |[[API17:JDatabaseSQLSrv::fetchAssoc|fetchAssoc]] | ||
|Method to fetch a row from the result set cursor as an associative array. | |Method to fetch a row from the result set cursor as an associative array. | ||
|- | |- | ||
|protected | |protected | ||
|[[JDatabaseSQLSrv::fetchObject | |[[API17:JDatabaseSQLSrv::fetchObject|fetchObject]] | ||
|Method to fetch a row from the result set cursor as an object. | |Method to fetch a row from the result set cursor as an object. | ||
|- | |- | ||
|protected | |protected | ||
|[[JDatabaseSQLSrv::freeResult | |[[API17:JDatabaseSQLSrv::freeResult|freeResult]] | ||
|Method to free up the memory used for the result set. | |Method to free up the memory used for the result set. | ||
|- | |- | ||
|} | |} | ||
* '''Defined in''' libraries/joomla/database/database/sqlsrv.php | * '''Defined in''' libraries/joomla/database/database/sqlsrv.php | ||
* '''Extends''' [[JDatabase | * '''Extends''' [[API17:JDatabase|JDatabase]] | ||
===Importing=== | ===Importing=== | ||
<source lang="php">jimport( 'joomla.database.database.sqlsrv' );</source> | <source lang="php">jimport( 'joomla.database.database.sqlsrv' );</source> | ||
===See also=== | ===See also=== | ||
* {{JVer|11.1}} '''JDatabaseSQLSrv source code''' on [[jplatform:database/database/sqlsrv.php|BitBucket]] | * {{JVer|11.1}} '''JDatabaseSQLSrv source code''' on [[jplatform:database/database/sqlsrv.php|BitBucket]] | ||
* {{JVer|11.1}} Subpackage [[Subpackage Database | * {{JVer|11.1}} Subpackage [[API17:Subpackage Database|Database]] | ||
* [[JDatabaseSQLSrv|Other versions of JDatabaseSQLSrv]] | * [[API17:JDatabaseSQLSrv|Other versions of JDatabaseSQLSrv]] | ||
{{SeeAlso:JDatabaseSQLSrv}} | {{SeeAlso:JDatabaseSQLSrv}} | ||
<span class="editsection" style="font-size:76%;"> | <span class="editsection" style="font-size:76%;"> | ||
Revision as of 01:23, 12 May 2013
JDatabaseSQLSrv
Description
Template:Description:JDatabaseSQLSrv [Edit Descripton]
Methods
| Visibility | Method name | Description |
|---|---|---|
| public | __destruct | Destructor. |
| public | connected | Determines if the connection to the server is active. |
| public | dateToString | Method to get a object represented as a datetime string in a format recognized by the database server. |
| public | explain | Diagnostic method to return explain information for a query. |
| public | getAffectedRows | Get the number of affected rows for the previous executed SQL statement. |
| public | getCollation | Method to get the database collation in use by sampling a text field of a table in the database. |
| public | getEscaped | Method to escape a string for usage in an SQL statement. |
| public | getExporter | Gets an exporter class object. |
| public | getImporter | Gets an importer class object. |
| public | getNumRows | Get the number of returned rows for the previous executed SQL statement. |
| public | getQuery | Get the current or query, or new object. |
| public | getTableCreate | Shows the table CREATE statement that creates the given tables. |
| public | getTableFields | Retrieves field information about the given tables. |
| public | getTableList | Method to get an array of all tables in the database. |
| public | getVersion | Get the version of the database connector. |
| public | hasUTF | Determines if the database engine supports UTF-8 character encoding. |
| public | insertid | Method to get the auto-incremented value from the last INSERT statement. |
| public | query | Execute the SQL statement. |
| public | queryBatch | Execute a query batch. |
| public | select | Select a database for use. |
| public | setUTF | Set the connection to use UTF-8 character encoding. |
| public | transactionCommit | Method to commit a transaction. |
| public | transactionRollback | Method to roll back a transaction. |
| public | transactionStart | Method to initialize a transaction. |
| public static | test | Test to see if the SQLSRV connector is available. |
| protected | __construct | Constructor. |
| protected | fetchArray | Method to fetch a row from the result set cursor as an array. |
| protected | fetchAssoc | Method to fetch a row from the result set cursor as an associative array. |
| protected | fetchObject | Method to fetch a row from the result set cursor as an object. |
| protected | freeResult | Method to free up the memory used for the result set. |
- Defined in libraries/joomla/database/database/sqlsrv.php
- Extends JDatabase
Importing
jimport( 'joomla.database.database.sqlsrv' );
See also
JDatabaseSQLSrv source code on BitBucket
Subpackage Database- Other versions of JDatabaseSQLSrv
Template:SeeAlso:JDatabaseSQLSrv [Edit See Also]
User contributed notes
<CodeExamplesForm />