PDO query mysql database _ PHP Tutorial

Source: Internet
Author: User
PDO queries the mysql database. PDO query mysql database this article provides a tutorial on how to operate an instance by phppdomysql, this is a mysql Query by phppdo and displays pdo query mysql tutorial database tutorial this article provides a PDO query mysql database this article provides a tutorial by php pdo mysql operation instance, this is where php pdo queries mysql data and displays

Pdo query mysql tutorial database tutorial
This article provides a php Tutorial on pdo mysql instance operations, which is used by php pdo to query mysql data and display
*/

Try {
$ Dbh = new pdo ($ beidou_connstr, $ beidou_user, $ beidou_pass );
Foreach ($ dbh-> query ('SELECT count (*) as count1, count (*) as count2 from bd_reve.user_day ') as $ row ){
Print_r ($ row );
}
$ Dbh = null;
} Catch (pdoexception $ e ){
Print "error! : ". $ E-> getmessage ()."
";
Die ();
}

Http://www.bkjia.com/PHPjc/630815.htmlwww.bkjia.comtruehttp://www.bkjia.com/PHPjc/630815.htmlTechArticlePDO query mysql database this article provides a by php pdo mysql operation instance tutorial, which is by php pdo query mysql data and show pdo query mysql tutorial database tutorial this article provides...

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.