dcgamers Posted August 17, 2007 Share Posted August 17, 2007 When you add a new column and you see the comments text box in phpmyadmin or something. How can you retrieve this using php and put it in a variable? Link to comment https://forums.phpfreaks.com/topic/65459-get-mysql-column-comments-with-php/ Share on other sites More sharing options...
js_280 Posted August 18, 2007 Share Posted August 18, 2007 $query = 'SELECT column_comment AS comment FROM information_schema.columns WHERE table_schema = "Database Name Here" && table_name = "Table Name Here" && column_name = "Column Name Here"'; $result = mysql_query($query, $connection) or die(mysql_error()); $comment = mysql_fetch_array($result); echo($comment['comment']); Link to comment https://forums.phpfreaks.com/topic/65459-get-mysql-column-comments-with-php/#findComment-327654 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.