vb.net interface with SQL database 2005,
Posted on 2011-03-19
we are in the process of planning to change our applications that written in VB6 (IDE) to vb.net
One of the questions we have is access data on the SQL. - we believe the SQL still runs the same
on the new 2008 srv R2. all the standard query and stored procedures are the same.
but from Vb6, we use the following way to interact with the SQL database on database server.
1. Use ADO recordset.
- dim rs_table as recordset
- set rs_table = createobject("adodb.recordset")
- strsql = "select * from table where ....."
- rs_table.open 'conn_db',......
if rs_table.eof = true a.......
set rs_table = nothing
2. we use bcp and osq utility on dos command to do some database export/import
The questions is, what will be changed on coding on vb.net? - I mean very basic 'console'
program that we runs on the background.
Please advice, and if someone can provide us some "sample" vb.net code (console type) will be highly appreciated. or refer to us some 'book' or reference documents.