• Advertisement


This topic is now archived and is closed to further replies.

Visual Basic: Finding the name of a field in a DB

This topic is 5712 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I''m not a big fan of Visual Basic, but I''ve got to get a project done in the next couple days, and I can''t find the answer to a specific question. My book doesn''t know the answer, my teacher doesn''t know the answer (to this or any other question I''ve asked the whole quarter, /rant), and I can''t find the answer on MSDN (I''m sure it''s on there somewhere , but I haven''t been able to find it in my searches, and if I spend any longer researching VB stuff, I''m afraid my head will begin spinning around in complete revolutions while bile spews from my eardrums) So, I''m asking you guys. How can I find the names of fields, the names of tables, the number of fields, and the number of tables in a database using recordset methods or SQL query strings with Visual Basic? I know I can get the value of a field in the current record using this syntax (along with a bunch of others):
But I need to be able to find out that, for example, "there are 3 fields per record, and they are named ''primaryKey'', ''carType'', and ''yearMade''". Same thing with tables, although that''s less important than the fields. Anyone know?

Share this post

Link to post
Share on other sites

  • Advertisement