Skip to content

Instantly share code, notes, and snippets.

@arkadiusjonczek
Created April 25, 2018 14:21
Show Gist options
  • Save arkadiusjonczek/4f3771168d67395d0647878cd3c79c1f to your computer and use it in GitHub Desktop.
Save arkadiusjonczek/4f3771168d67395d0647878cd3c79c1f to your computer and use it in GitHub Desktop.
MySQL Show Column Data Types #tags: MySQL
SELECT DATA_TYPE FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'oxarticles' AND COLUMN_NAME = 'OXID';
SELECT
COLUMN_NAME, DATA_TYPE
FROM
INFORMATION_SCHEMA.COLUMNS
WHERE
TABLE_SCHEMA = 'ods'
AND
TABLE_NAME = 'oxarticles';
SHOW FIELDS FROM oxarticles
EXPLAIN ods.oxarticles;
DESCRIBE ods.oxarticles;
SHOW FIELDS FROM ods.oxarticles;
SHOW COLUMNS FROM ods.oxarticles;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment