I am programming in
VB 2008 using
VB script. I have a query that should get me data from Oracle database and fill the table in
VB. It usually gets about 4 out of 40 records and then I get this error. If I run this query using TOAD the results are returned in less than 1 minute. There are times when I do not get this error and the table is filled with no issues.
I also tried disabling the ContextSwitchDeadlock through the Debug menu. Then it just hangs.
Any help/advice will be greatly appreciated.
It chokes on the line :
adoDA.Fill(adoDS, TableName)
Public Sub GetOracleTable(ByVal SQL As String, ByVal TableName As String, ByRef adoDS As DataSet, ByVal ConnString As String, Optional ByVal ClearTable As Boolean = True)
Using adoDA As New OracleClient.OracleDataAdapter(SQL, ConnString)
Try
If ClearTable AndAlso adoDS.Tables.Contains(TableName) Then
adoDS.Tables(TableName).Clear()
End If
adoDA.Fill(adoDS, TableName)
Catch ex As Exception
Throw ex
End Try
End Using
End Sub