Here I will teach you about MYSQL syntax.
MYSQL is mostly used by web developers use MYSQL inside their language to build applications that access data in a database.
Database work on four fundamentals.
- Read Data From Database - SELECT
- Insert new data into Database - INSERT
- Update exist data into Database - UPDATE
- Delete Data from Database - DELETE
This four fundamental referred to as CRUD (Create, Read, Update, Delete).
The MYSQL SELECT Syntax
SELECT column-names
FROM table-names
WHERE conditions
ORDER BY sort-order
Example
SELECT name, surname, email, city
FROM users
WHERE email = 'contact@webappfix.com'
ORDER BY name
The MYSQL INSERT Syntax
INSERT table-name (column-names)
VALUES (column-values)
Example
INSERT users (name, surname, email, city)
VALUES ('Dharmesh', 'Chauhan', 'contact@webappfix.com', 'Rajkot')
Laravel 6 validation with error message
The MYSQL UPDATE Syntax
UPDATE tableName
SET columnName = columnValue
WHERE condition
Example
UPDATE users
SET city = 'Ahemdabad'
WHERE id = 3908
The MYSQL DELETE Syntax
DELETE table-name
WHERE condition
Example
DELETE users
WHERE email = 'contact@webappfix.com'
I hope it can helpful for you.
Thanks for read.
We always thanks to you for reading our blogs.
Dharmesh Chauhan
(Swapinfoway Founder)Hello Sir, We are brothers origin from Gujarat India, Fullstack developers working together since 2016. We have lots of skills in web development in different technologies here I mention PHP, Laravel, Javascript, Vuejs, Ajax, API, Payment Gateway Integration, Database, HTML5, CSS3, and Server Administration. So you need our service Please Contact Us
Haresh Chauhan
(Co-Founder)We Are Also Recommending You :
- How To Install MongoDB In Ubuntu
- ERROR: database "laravel" is being accessed by other users DETAIL: There is 1 other session using the database.
- How To Improve SQL Query Performance
- How to See Pgsql Database List in Ubuntu
- How To Change ENUM DataType Without Losing Data Laravel Migration
- Create Database In MYSQL Using PHP Script Example
- SOLVED # 1118 Row size too large 8126. Changing some columns to TEXT or BLOB
- MongoDB Database Connection In Laravel
- Postgres Database Export
- The Syntax of MySQL