6月18日設置
Posted by No Name Ninja - 2007.07.22,Sun
Imports System.Data.OleDb
Private Function hogeDb() As Boolean
Dim sqlConn As OleDbConnection
Dim strConn As String
Dim strSql As String
Dim sqlCmd As OleDbCommand
Dim sqlRec As OleDbDataReader
Dim strField As String
strConn = strConn & "Provider = hoge"
strConn = strConn & ";Data Source = hoge"
strConn = strConn & ";User Id = hoge"
strConn = strConn & ";Password = hoge"
strConn = strConn & ";"
sqlConn = New OleDbConnection
sqlConn.ConnectionString = strConn
sqlConn.Open()
strsql = "select * from hoge"
sqlCmd = New OleDbCommand
sqlCmd.CommandText = strSql
sqlCmd.Connection = sqlConn
sqlCmd.CommandTimeout = 10
sqlRec = sqlCmd.ExecuteReader
strField = sqlRec("FIELD")
sqlRec.Close()
sqlRec = Nothing
sqlCmd.Dispose()
sqlConn.Close()
End Function
PR
Comments
Post a Comment
カレンダー
カテゴリー
フリーエリア
最新コメント
[05/16 backlink service]
最新記事
(09/18)
(11/17)
(10/03)
(07/21)
(07/20)
最新トラックバック
プロフィール
HN:
No Name Ninja
性別:
非公開
ブログ内検索
最古記事
カウンター
アクセス解析
Template by mavericyard*
Powered by "Samurai Factory"
Powered by "Samurai Factory"