Database Development FAQs & Tutorials [updated May 13 2011]
Database Development FAQ
The following is a list of frequently asked questions for working with databases, including how to use databases from VB, and creating/designing/managing databases.
Note that if you have a question which isn't answered here, it may be in another of our FAQ threads, such as the Classic VB FAQs, or the Office Development FAQs
If you can think of a "frequent" question (and preferably an answer to it as well) that you think should be added to these FAQs, please see this thread.
____________________________________________________________ Recent Additions
May 13 2011 : [General] How can I run an ADODB based program that was compiled on Windows 7 SP1?
Mar 8 2011 : [General] How to connect to a database on the internet
Mar 29 2010 : [General] Why dont AutoNumber/Identity/etc re-use deleted numbers?
How can I use a database in my program?
For Classic VB (VB6 and earlier) see the Classic VB - ADO section.
For VB.Net (VB2002 or later, and Express) see VB.Net section.
How can I create an Access database using code?
See this article at CodeGuru.
ADO.NET Entity Framework Tutorial
ADO.NET Entity Framework maps business entities in your database to logical objects in your code allowing you to work across them in an easy, efficient manner.
Where can I find the ADO.Net documentation?
It can be found online at MSDN here
How can I add a record to a database? (includes using a Recordset, connection.Execute, a Command object, and a Stored Procedure - and discusses which is best for different situations)
SQL Server 2005 useful info
(contains several links in Post #4, including the Free version of SQL Server 2005, tools for it, and the help files [Books Online])
How can I configure SQL Server 2005 to allow remote connections?
See this MS KB article
How can I import/export data from other database systems/files?
See this thread and this thread from our Office Development FAQ's, which use Excel files as an example (the same methods can be used for other sources/targets).
How can I write a Stored Procedure?
See this tutorial
How can I debug a Stored Procedure?
See this tutorial
How can I enable connections from other computers?
See this MS KB article