MySQL Tutorials

Copy data from one column to another column in MySQL

In this tutorial I will show you how to copy data from one column to another column in same table in MySQL. There is a simple query to update record from one to another column in MySql. Most of the time we just need to copy a particular record from one table to another but sometime we need to copy the whole column values to another column in same table. …

Continue reading

Main differences between InnoDB and MyISAM

Most commonly used storage engine in MySQL are MyISAM and InnoDB. The default storage engine chosen by MySQL database is MyISAM. There are some advantages and disadvantages of these storage engine according to application needs. Main differences between InnoDB and MyISAM MyISAM does not support transactions by tables while InnoDB supports. InnoDB does not support FULLTEXT index while MyISAM supports. Performance speed of MyISAM table is much higher as compared …

Continue reading

PHP MySQL Interview Questions and Answers Set – 3

In this tutorial we are providing some set of frequently asked PHP MySQL Interview Questions which will help you to get success in interview. Read PHP interview questions and answers Set – 2. How can we connect to a MySQL database from a PHP script? To be able to connect to a MySQL database, we must use mysql_connect() function as follows: What is the function mysql_pconnect() usefull for? mysql_pconnect() ensure …

Continue reading

Convert Data from MySQL to JSON using PHP

Convert Data from MySQL to JSON using PHP

Converting data from MySQL to JSON format in PHP, is one of the most prominent task in web development. JSON is the most preferred data format over xml as data exchange between web and mobile applications. JSON format has it’s own advantages like light weight, ability to store complex data structures in plain text and human readability. In previous post we have already discussed about converting JSON data into MySQL …

Continue reading

Some Tricks to Sort Out the utf-8 Problem

Some Tricks to Sort Out the utf-8 Problem

Everyone already knows about utf-8 problem, but sometimes the issue still persists even after approaches so many solutions. So in this tutorial I am including some tricks that will surly help you to sort out the utf-8 problem. Like the problem with currency symbols(£, ₹), the solution is based on HTML, PHP and MySQL tricks. In PHP you should use following line: You can set content type using following meta …

Continue reading

MySQL server has gone away in Magento

MySQL server has gone away in Magento

Recently I faced a problem MySQL server has gone away in Magento when I was moved the code from one hosting to another hosting. Actually the problem came into notice when I try to place order sometimes it sends me back to cart page and sometimes after the successful payment via standard PayPal the order status didn’t change and remain as pending payment. Then I trace the problem by checking …

Continue reading

User Signup and Signin with PHP and MySQL

User Signup and Signin with PHP and MySQL

Authentication system is the most important part for the developers to implement in a web application. It is necessary if you want to provide limited access of your application for anonymous user. If you want to create a web application with secure admin area or a user signup and signin with php and mysql this post will help you. Here are the steps to create a simple application that allow …

Continue reading

Difference Between PDO And MySQLi

Difference Between PDO And MySQLi

We have two choices for accessing the database in PHP : MySQLi and PDO. We have already compared them with old mysql extension in Difference between mysql and pdo and Difference between MySQL and MySQLi. In this article, we will discuss difference between PDO and MySQLi on various feature like database support, stability and performance to find which is the better API. Connection : // PDO // mysqli, procedural style …

Continue reading