Answers for "how to get all field name of table in my sql"

SQL
0

mysql select all table that have field names

SELECT DISTINCT
	TABLE_NAME
FROM
	INFORMATION_SCHEMA.COLUMNS
WHERE
	COLUMN_NAME IN('column1', 'column2')
	AND TABLE_SCHEMA = 'schema_name';
Posted by: Guest on November-12-2020
0

mysql get only the field names in a table

SELECT column_name
FROM information_schema.columns
WHERE  table_name = 'your_table'
   AND table_schema = 'database_name'
Posted by: Guest on September-23-2021

Code answers related to "how to get all field name of table in my sql"

Code answers related to "SQL"

Browse Popular Code Answers by Language