Get Column Name from table using SQL
To retrieve the column names from a table in SQL, you can use the INFORMATION_SCHEMA.COLUMNS table, which contains information about columns in all tables in the databas
Example
SELECT COLUMN_NAME
FROM INFORMATION_SCHEMA.COLUMNS
WHERE TABLE_NAME = 'YourTableName';