Skip to content

Commit

Permalink
Merge pull request #263 from nikhilkalburgi/nikhilkalburgi-patch-1
Browse files Browse the repository at this point in the history
Add Truncate and rename cmds to MYSQL_Cheatsheet.md
  • Loading branch information
Jahenr authored Mar 24, 2024
2 parents 1945c3e + e3a3594 commit e17a84a
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions MYSQL_Cheatsheet.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,16 @@ MYSQL
#Deletes multiple views.
DROP VIEW VIEW1,VIEW2…;
#Truncate a table
TRUNCATE [TABLE] table_name;
#Rename a table
RENAME TABLE table_name TO table_name;

#return the number of rows
SELECT COUNT(*) FROM TABLENAME

#Use of IN operator with WHERE clause
SELECT <field_list> FROM <table_name> WHERE <expression|column_1> IN (value1, value2, …)


0 comments on commit e17a84a

Please sign in to comment.