I am having trouble extracting data from a lotus notes database to a table on a sql server. With the code that I am using it either puts me in an infinate loop or does not extract any data. This is code that I am using can you please let me know your thoughts or if I am doing something wrong.
Thanks for the help
Christy
Dim conn As New ODBCConnection
Dim qry As New ODBCQuery
Dim result As New ODBCResultSet
Dim tmpStreet As String
Dim tmpCity As String
Dim tmpZip As String
If conn.ConnectTo("Christy") Then
Set Qry.Connection = conn
qry.SQL = "Select * From dbo.SIUMailDrop"
Set result.Query = qry
result.Execute
Do
result.NextRow
Call result.SetValue("FormName", doc.Form(0))
Call result.SetValue("Name", doc.MailDropName(0))
Call result.SetValue("Address", doc.MailDropAddress(0))
result.UpdateRow
Loop Until result.IsEndOfData
’ result.Close(DB_CLOSE)
’ conn.Disconnect
Else
Beep
Messagebox "Cannot connecct to server."
Exit Sub
End If
result.Close(DB_CLOSE)
conn.Disconnect
Exit Sub