PDO Knowledge point 1

Source: Internet
Author: User

pdo::begintransaction-Start a transaction
pdo::commit-Commit a transaction
pdo::__construct-creating a PDO instance that represents a database connection
Pdo::errorcode-gets the SQLSTATE associated with the last operation of the database handle
Pdo::errorinfo-fetch extended error information associated with the last operation on the database handle
pdo::exec-executes an SQL statement and returns the number of rows affected
Pdo::getattribute-retrieving the properties of a database connection
pdo::getavailabledrivers-returns an array of available drives
pdo::intransaction-check whether within a transaction
Pdo::lastinsertid-returns the ID or sequence value of the last inserted row
PDO::p repare-prepares A statement for execution and returns a statement object
Pdo::query-executes an SQL statement, returning a result set as a Pdostatement object
Pdo::quote-quotes a string for use in a query.
pdo::rollback-rolling back a transaction
pdo::setattribute-Setting properties

Exception::getmessage-gets the content of the exception message.
exception::getprevious-returns the previous exception in the exception chain
exception::getcode-Getting exception codes
Exception::getfile-Gets the program file name of the exception that occurred
Exception::getline-gets the line number of the code in the file where the exception occurred
exception::gettrace-getting exception tracking information
exception::gettraceasstring-getting exception tracking information for a string type
exception::tostring-to convert an exception object to a string
exception::clone-Abnormal cloning

           

PDO Knowledge point 1

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.