CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2

Thread: Table Columns

  1. #1
    Join Date
    Jun 1999
    Location
    Rochester, NY
    Posts
    45

    Table Columns

    Does anyone know of a way to query a table and receive back the names of the columns in that table. Basically
    what I want to do is make a generic function that you pass a table name tol bind all column names for creating SQL
    queries. If anyone knows of a way to do this, I would be appreciative.

    -Dan


  2. #2
    Join Date
    May 1999
    Posts
    44

    Re: Table Columns

    You can retrieve a column name and data type with CDaoRecordSet::GetFieldInfo for DAO database or SQLColAttributes with SQL_COLUMN_NAME as the descriptor type for ODBC.


Posting Permissions

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





Click Here to Expand Forum to Full Width

Featured