RE: [PHP] retrieving ENUM description from MySQL

2003-11-20 Thread Jeff McKeon
Here's an example of how to get the ENUM into a drop down list in a web form. I use it all the time.. [code] /* Get_Enum : Retreives the "enum" options from an "enum" type field in a MySql Database */ function Get_enum($table,$field,$db,$link) { mysql_select_db($db,$link); $result = mysql_que

Re: [PHP] retrieving ENUM description from MySQL

2003-11-19 Thread John W. Holmes
Alan Lord wrote: Imagine a database table, field defined as ENUM with a list of allowed types such as "Mr", "Mrs", "Miss", "Dr", "Prof", etc - you get the idea. I've read the MySQL manual and by using SHOW COLUMNS FROM "table_name" LIKE "enum_column_name"; I can get a result. But the string of