Click to See Complete Forum and Search --> : primary key


princeap
August 18th, 2000, 07:16 AM
how can i know that which is the primary key in a table using ADO..I am working with VC++

Johnny101
August 18th, 2000, 11:07 AM
I'm not sure that plain ADO will/can tell you about primary keys - but i do know that ADOX will. It's available with MDAC 2.1 or higher. The DLL name is msadox.dll. It's usually found in the C:\Program Files\Common Files\System\Ado folder. I'm not a C++ guy, so I can't offer any sample code, sorry. The MSDN has some good documentation of ADOX. It's just as easy as ADO to use.

Hope this helps,

John

John Pirkey
MCSD
http://www.ShallowWaterSystems.com
http://www.stlvbug.org