Skip to content

Instantly share code, notes, and snippets.

@mfrata
Created May 28, 2018 17:29
Show Gist options
  • Save mfrata/2c27222c965875d291dbb9634066ff65 to your computer and use it in GitHub Desktop.
Save mfrata/2c27222c965875d291dbb9634066ff65 to your computer and use it in GitHub Desktop.
Table columns names and data type
SELECT column_name, data_type
FROM information_schema.columns
WHERE table_schema = 'your_schema'
AND table_name = 'your_table'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment