Results 1 to 4 of 4
  1. #1
    Join Date
    Nov 2003
    Location
    Sydney
    Posts
    4

    Arrow Unanswered: Retrieving column properties

    Is there an SQL statement l can use from within PHP to extract all the column names, data types etc from a table?

    Thanks in advance

    P.S First post, this'll email when an answer happens right ?

  2. #2
    Join Date
    Nov 2003
    Location
    Sydney
    Posts
    4
    How about retrieving column names then ?

    Would think there would be an SQL statement to do this ?????

  3. #3
    Join Date
    Nov 2003
    Posts
    1

    Re: Retrieving column properties

    Originally posted by jumpup
    Is there an SQL statement l can use from within PHP to extract all the column names, data types etc from a table?

    Thanks in advance
    for table:
    mysql_query("show tables");

    for columns
    mysql_qeury("show columns from TABLENAME");

    Try the query into mysql client and you understand how to use it under PHP.

    bye from italy

  4. #4
    Join Date
    Nov 2003
    Location
    Sydney
    Posts
    4
    Thanks for the info zio

    Actually will be running the command in visual basic this time round

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •