Created
June 27, 2014 01:45
-
-
Save brendanashworth/ac0a0c27f459778e17f4 to your computer and use it in GitHub Desktop.
MySQL command reference
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Select, insert, update, delete | |
SELECT * FROM `my_table` WHERE `my_field` = 'my_value'; | |
INSERT INTO `my_table` (my_field, another_field) VALUES ('myFieldValue', 'AnotherFieldValue'); | |
UPDATE `my_table` SET `my_field` = 'aNewValue'; | |
DELETE FROM `my_table` WHERE `my_field` = 'a_special_value'; | |
# Get the schema of sorts for a table | |
SHOW COLUMNS FROM `my_table`; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment