What is MySQL query in PHP

In this article I am going to explain about MySQL queries.
  • 1812


A query is a request or question. We can query to a database for specific information and recordset returned. Queries are different types, some of query examples are given below:

  • Query of select statement

    You can use select statement for retrieving values in database or table. The given example retrieve hole table data.

Example of select query

SELECT * from tableName

  • Query of  insert statement

    You can use insert value by the help of insert statement.

Example of insert query

INSERT INTO tableName values(value1,value2,...............)

  • Query of update statement

    By the help of update query , you can update table values.

Example of update query

UPDATE  tableName set columnName= NewValue where columnName=OldValue;

  • Query of delete statement

    By the help of delete  query, you can perform delete operation on table.

Example of delete query

DELETE from tableName where columnName(operator) value;

You may also want to read these related articles click here

Ask Your Question 

Got a programming related question? You may want to post your question here

Programming Answers here

© 2020 DotNetHeaven. All rights reserved.