How to find column name in MySQL?

How to get the column name? What is the request for this?

Thank.

+3
source share
4 answers

SHOW COLUMNS command can be used to retrieve column names in a table

http://dev.mysql.com/doc/refman/5.0/en/show-columns.html

+2
source

You can use SHOW COLUMNS , which displays information about the columns in this table.

0
source

DESCRIBE tableName will give you the names of all the columns in the table.

0
source

This is a fairly broad context.

You can try something as simple as

describe `table_name`;
0
source

Source: https://habr.com/ru/post/1776383/


All Articles