|
Posted by Marek Simon on 02/02/06 10:12
Keep in mind, that these column and DB-structure operations are usualy
DB-specific, commands working in one DB-platform will not work in other
DB-platform.
Marek
NC wrote:
> johnny wrote:
>
>>I need to set up a script which ,after receiving from a form the
>>table name, can print the first known fields,and all the additional
>>ones , but I don' t want it to show the last 2 columns of the table
>>because they store sensitive or useless contents.
>
>
> You can get a list of fields in a table by running a query like this:
>
> SHOW FIELDS FROM [table_name];
>
> or
>
> SHOW COLUMNS FROM [table_name];
>
> Then you can write all names into an array and simply skip the last two
> when outputting the list into the browser...
>
> Cheers,
> NC
>
[Back to original message]
|