Help! I have a flat file that I need to compare against to a table already populated in SQL6.5. I know how to open and read the file to an array on VB5.0 but I don't know how to connect to the SQL server and run a Qry to check each line.

Does any one have a snippet that shows me how to first connect to to the server, then run a simple query against a table.