Source Code: Basic MySQL Query

freemysqlquery

MySQL is the most common database back-end used by many web and desktop application today. The basic function of MySQL is to hold or keep data submitted by any web and desktop application. Below are the basic MySQL query for saving, update, deleting and loading data from MySQL and display it to any Programming languages like Java, PHP, or VB.NET.

Saving Data

INSERT INTO yourtable VALUES('Data1','Data2','Data3')

Update Data

UPDATE tablename SET column1='NewData' WHERE tblid='sampleid1'

Delete Data

DELETE FROM tablename WHERE tblid='sampleid1'

Loading Data

Load all data from MySQL Table

SELECT * FROM tablename

Load specific data from MySQL Table

SELECT column1, column2 FROM tablename

 

Leave a Reply

Be the First to Comment!

Notify of
avatar
wpDiscuz