Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

OO40 Problem using excel vba

Status
Not open for further replies.

GBall

Programmer
Joined
May 23, 2001
Messages
193
Location
GB
Hi,
can anyone tell me what is wrong with this code, as I get an error on the oradatabase.execute statement that informs me that 'Object does not support this property or method'

thanks.


Private Sub Zeroise_Amount_Fields()
Dim strSql As String
Dim strDB As String
Dim strSchema As String
Dim oraSession As Object
Dim oraDatabase As Object
Dim ln As Integer

strSql = "update t_ddd_complaint_details set "
strSql = strSql & "compensation_amt = " & 0 & ", "
strSql = strSql & "ex_gratia_amt = " & 0 & ", "
strSql = strSql & "fees_amt = " & 0 & ", "
strSql = strSql & "interest_amt = " & 0 & ", "
strSql = strSql & "inv_return_amt = " & 0 & ", "
strSql = strSql & "policy_surrender_amt = " & 0 & ", "
strSql = strSql & "vouchers_amt = " & 0 & ";"

strDB = "test.world"
strSchema = "scott/tiger"
Set oraSession = CreateObject("OracleInProcServer.XOraSession")
Set oraDatabase = oraSession.OpenDatabase(strDB, strSchema, 0&)
oraDatabase.Execute (strSql)

oraDatabase.Close
Set oraDatabase = Nothing

End Sub


Regards,
Graham
 
Hi.
The methode is called ExecuteSQL.

Stefan
 
Couldn't see for looking !!
thanks.

Regards,
Graham
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top