A very good tool. Works for MySQL.
Here is a list of free downloads:
http://code.google.com/p/sqlyog/downloads/list
(don't try to download it from their site since it's not free anymore, these copies are the ones they used to give as freeware).
Showing posts with label MySQL. Show all posts
Showing posts with label MySQL. Show all posts
Friday, March 5, 2010
Friday, December 5, 2008
DB.class
I created this class to help my self save some time writing code to access a MySQL DB.
It contains all the esential methods to connect to the DB, execute a SELECT, execute a DML (insert, update, delete) and retrieve relevant information about the last query executed (result, number of affected rows, last id inserted).
The idea is to extend this class when you want to access a table of your DB and reuse the methods without re-typing all the lines of code to connect to the DB, fetch the results, evaluate if errors were returned, etc.
///////Put code of the class here
All your now code is reduced to:
- Create a class that extends this one.
- Write your query (simple string).
- Call one of the methods of the DB class that already handles everything else (connection, execution, fetching results, building returning message of OK or ERROR).
//Put example of how to use it here
I hope you find this class useful. Any comments are welcome.
It contains all the esential methods to connect to the DB, execute a SELECT, execute a DML (insert, update, delete) and retrieve relevant information about the last query executed (result, number of affected rows, last id inserted).
The idea is to extend this class when you want to access a table of your DB and reuse the methods without re-typing all the lines of code to connect to the DB, fetch the results, evaluate if errors were returned, etc.
///////Put code of the class here
All your now code is reduced to:
- Create a class that extends this one.
- Write your query (simple string).
- Call one of the methods of the DB class that already handles everything else (connection, execution, fetching results, building returning message of OK or ERROR).
//Put example of how to use it here
I hope you find this class useful. Any comments are welcome.
Books I recommend
PHP & MySQL
HTML, XML and others -ML
- Beginning PHP5 and MySQL5 - From Novice to Professional-2e-2006-APress
- Professional Ajax Php
- Professional LAMP - Linux, Apache, MySQL, & PHP5 Web Development (2006)
- Javascript Bible 4th Edition
- O'reilly - Javascript - The Definitive Guide, 4th Edition
HTML, XML and others -ML
- OReilly XML Pocket Reference 2nd
Subscribe to:
Posts (Atom)