?
Solved

Get MySQL comments metadata

Posted on 2006-04-07
3
Medium Priority
?
1,197 Views
Last Modified: 2006-11-18
I know you can do "SHOW FULL COLUMNS FROM tablename" to list out all the fields and all the data associated to those fields, but I'm interested in just grabbing the comment datum for one particular field.  Is this possible?  Assume MySQL 5+

I know I could parse the output in PHP and grab it that way, but you'd think there would be a better way.

Thanks.
0
Comment
Question by:BrianPap22
  • 2
3 Comments
 
LVL 30

Accepted Solution

by:
todd_farmer earned 80 total points
ID: 16406089
Use INFORMATION_SCHEMA in 5.0+:

SELECT column_comment FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME='table_name';
0
 
LVL 4

Author Comment

by:BrianPap22
ID: 16409873
Thank you very much sir!
0
 
LVL 30

Expert Comment

by:todd_farmer
ID: 16411779
Glad to help - thanks for the points!
0

Featured Post

Restore individual SQL databases with ease

Veeam Explorer for Microsoft SQL Server delivers an easy-to-use, wizard-driven interface for restoring your databases from a backup. No expert SQL background required. Web interface provides a complete view of all available SQL databases to simplify the recovery of lost database

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this series, we will discuss common questions received as a database Solutions Engineer at Percona. In this role, we speak with a wide array of MySQL and MongoDB users responsible for both extremely large and complex environments to smaller singl…
This post looks at MongoDB and MySQL, and covers high-level MongoDB strengths, weaknesses, features, and uses from the perspective of an SQL user.
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
Suggested Courses
Course of the Month13 days, 14 hours left to enroll

755 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question