MySQL
  Home arrow MySQL arrow Implementing the commit() and rollback() Methods with mysqli and PHP 5
Dev Shed Forums  
Administration  
AJAX  
Apache  
BrainDump  
DHTML  
Flash  
Java  
JavaScript  
Multimedia  
MySQL  
Oracle  
Perl  
PHP  
Practices  
Python  
Reviews  
Security  
Smartphone Development  
Style-Sheets  
Web Services  
XML  
Zend  
Zope  
Mobile Linux  
App Generation ROI  
IBM® developerWorks  
Forums Sitemap  
E-Commerce Hosting  
Linux Web Hosting  
Managed Hosting  
Small Business Hosting  
VPS Hosting  
Weekly Newsletter

 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid  
Request Media Kit
Contact Us  
Site Map  
Privacy Policy  
Support  
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
MYSQL

Implementing the commit() and rollback() Methods with mysqli and PHP 5
By: Alejandro Gervasio
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: starstarstarstarstar / 15
    2006-07-03


    Table of Contents:
  • Implementing the commit() and rollback() Methods with mysqli and PHP 5
  • Working with “InnoDB” tables: using the “commit()” and “autocommit()” methods
  • Canceling database modifications: using the “rollback()” method
  • Escaping strings, counting rows and more: using the “real_escape_string()” method and the “affected_rows” property

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      error-file:tidyout.log Del.ici.ous error-file:tidyout.log Digg
      error-file:tidyout.log Blink error-file:tidyout.log Simpy
      error-file:tidyout.log Google error-file:tidyout.log Spurl
      error-file:tidyout.log Y! MyWeb error-file:tidyout.log Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article

     
     
    ADVERTISEMENT


    Implementing the commit() and rollback() Methods with mysqli and PHP 5
    ( Page 1 of 4 )

    If you want to use the "mysqli" extension, you've come to the right place. This is the second part of the series “Using mysqli with PHP 5.” Welcome back. In three tutorials, this series shows how to use the most important methods and properties included in the “mysqli” extension that comes with PHP 5, in order to take advantage of the new features bundled with MySQL 4.1 and above.

    Introduction

    Stepping back for a moment to the topics that I covered in the first tutorial, you’ll probably remember how to connect to the MySQL server and use the “multi_query()” method for running multiple queries, in addition to handling several result sets at the same time. This can definitely can introduce significant changes to the way that you develop your MySQL-based applications.

    Also, I’d like to mention the great functionality provided by this extension to bind different queries to specific parameters, which are replaced with real values during the execution of an application. This particular feature allows the definition of “generic” queries that eventually will be attached to different arguments, resulting in an easier and more flexible process for generating dynamic queries.

    All right, I believe that all the topics I mentioned before are now fresh in your mind. Therefore it’s time to move on and focus our attention on the subject of this second article, so you know what to expect from it. Over the course of this installment, I’ll explain how to use the “commit()” and “rollback()” methods included within the “mysqli” library, among other handy methods, which hopefully will provide you with a more robust grounding in the capabilities of MySQL 4.1 and above.

    Are you ready to continue learning more about all these useful features? Okay, let’s get started!



     
     
    >>> More MySQL Articles          >>> More By Alejandro Gervasio
     

       

    MYSQL ARTICLES

    - MySQL Security Tips
    - Designing a MySQL Database: Tips and Techniq...
    - The Three Most Important MySQL Queries
    - Null and Empty Strings
    - MySQL Server Tuning Tips and Tricks
    - MySQL Query Optimizations and Schema Design
    - MySQL Benchmarking Tools and Utilities
    - MySQL Benchmarking Concepts and Strategies
    - Take Some Load off MySQL with MemCached
    - MySQL Table Prefix Changer Tool in PHP
    - Using the SIGNAL Statement for Error Handling
    - Error Handling Examples
    - Error Handling
    - Completing a Search Engine with MySQL and PH...
    - Paginating Result Sets for a Search Engine B...





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 6 Hosted by Hostway
    Stay green...Green IT