Re: [PHP] output the schema

2007-08-07 Thread Richard Lynch
On Fri, August 3, 2007 6:34 am, Richard Heyes wrote: >> I reword my last post. >> >> I want to take the result and generate the field info to the screen >> e.g > > Well, if you're using MySQL you could use either "DESC ;" or > "SHOW CREATE ...". But you can't really generate the schema from a > res

RE: [PHP] output the schema

2007-08-03 Thread Uber Wannabe
You would probably want to use the combination of the MySQL query "SHOW COLUMNS FROM " and the PHP function mysql_field_type(). An example would be: ) or die(); //Dummy variable for incrementing current field $count = 0; while($row = mysql_fetch_row($result)

Re: [PHP] output the schema

2007-08-03 Thread Richard Heyes
I reword my last post. I want to take the result and generate the field info to the screen e.g Well, if you're using MySQL you could use either "DESC ;" or "SHOW CREATE ...". But you can't really generate the schema from a result set. -- Richard Heyes +44 (0)844 801 1072 http://www.websuppo