There is an example in the \TestStand\Examples\Database directory. Basically there are two ways to connect to your database.
1. You can use the TestStand database step types. There are steps for opening/closing a database connection, opening/closing an SQL statement, and a step for performing a data operation.
2. The other way is to use the TestStand database logging capability to write your results to the database. This is the way I would recommend. With database logging, you use the step results container to record all your results as the sequence runs. (This is done automatically by TestStand). When the sequence is complete, the process model calls a "Log to Database" sequence that will write the results to the database. You must define your datab
ase schema using Configure->Database Options. There are some default (or example) schema definitions already defined. Refer to chapter 18 of your TestStand manual.
Another way to log the data as the sequence is running is shown in the \TestStand\Examples\OnTheFlyReports. This has the advantage of recording data as it is obtained, but it is not as efficient in terms of using a database connection. I don't recommend using this method.
Please post again if you have any more questions. If you are using stored procedures with your database, I can probably give you some tips.
Mark