Hi All,
I'm new to PHP4, but am enjoying some limited success integrating it with a MS-Access (ODBC) database.
I am creating a PHP function which will automatically analyze the columns in a given table and generate .php pages which allow HTML administration of the table (add, delete, edit DB records).
I'd like to make this as flexible as possible, and to this end, I want to query a specific table and retrieve the specific column information. When I code:
$allColumns = odbc_columns($db);
I get a database dump of ALL columns in ALL tables ($db is my database connection).
Here's what I don't understand: How do I use the optional parameters in the odbc_columns function to restrict the output to only one table? I've tried:
$allColumns = odbc_columns($db,"","","thistable","");
but I keep getting SQL errors:
SQL error: , SQL state 00000 in SQLColumns....
Can anyone please offer any insights? I'm sure this is possible....
Thanks,
michael geary
I'm new to PHP4, but am enjoying some limited success integrating it with a MS-Access (ODBC) database.
I am creating a PHP function which will automatically analyze the columns in a given table and generate .php pages which allow HTML administration of the table (add, delete, edit DB records).
I'd like to make this as flexible as possible, and to this end, I want to query a specific table and retrieve the specific column information. When I code:
$allColumns = odbc_columns($db);
I get a database dump of ALL columns in ALL tables ($db is my database connection).
Here's what I don't understand: How do I use the optional parameters in the odbc_columns function to restrict the output to only one table? I've tried:
$allColumns = odbc_columns($db,"","","thistable","");
but I keep getting SQL errors:
SQL error: , SQL state 00000 in SQLColumns....
Can anyone please offer any insights? I'm sure this is possible....
Thanks,
michael geary