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? Quote 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']); Quote 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
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.