To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=67290
Issue #|67290
Summary|com.sun.star.lang.DisposedExeption after 2nd SQL-Query
| in 2.0.3
Component|Database access
Version|OOo 2.0.3
Platform|PC
URL|
OS/Version|Windows XP
Status|UNCONFIRMED
Status whiteboard|
Keywords|
Resolution|
Issue type|DEFECT
Priority|P3
Subcomponent|none
Assigned to|dbaneedsconfirm
Reported by|r_rethmann
------- Additional comments from [EMAIL PROTECTED] Wed Jul 12 10:12:46 -0700
2006 -------
Hi there,
I've been working with 2.0.2 for a while now and just upgraded to 2.0.3.
After upgrading my scripts don't work any longer.
I'm accessing my Sybase SQL Anywhere 8 Server through ODBC.
This simple script shows the issue:
Sub Test
Dim oStatement as Object, sQuelle as String, sUser as String, sPW as String
Dim oState as Object, oDatabaseContext as Object, oDatenquelle as Object
DimsSQL as String, oResult as Object, oDVerb as Object
sQuelle = "database"
sUser = "user"
sPW = "***"
oDatabaseContext = createUnoService("com.sun.star.sdb.DatabaseContext")
If oDatabaseContext.hasByName(sQuelle) then
oDatenquelle = oDatabaseContext.getByName(sQuelle)
oDVerb = oDatenquelle.getConnection(sUser,sPW)
oStatement = oDVerb.createStatement()
oStatement.ResultSetType = com.sun.star.sdbc.ResultSetType.SCROLL_SENSITIVE
oStatement.ResultSetConcurrency = com.sun.star.sdbc.ResultSetConcurrency.
UPDATABLE
oStatement.EscapeProcessing = True
' read data from first table
sSQL = "SELECT FIRST ID FROM Daten"
oResult = oStatement.executeQuery(sSQL)
If not isNULL(oResult) and oResult.Next() then
MsgBox("First table data: " & oResult.getInt(1), 64, "Database Test")
End If
' Result: MsgBox displays data
' read data from second table
sSQL = "SELECT FIRST ID FROM Mitarbeiter"
oResult = oStatement.executeQuery(sSQL)
' in 2.0.3 I'll get a runtime error here: Exeption - com.sun.star.lang.
DisposedExeption (no further message)
' oStatement still exists
' in 2.0.2 it works
If not isNULL(oResult) and oResult.Next() then
MsgBox("Second table data: " & oResult.getInt(1), 64, "Database Test")
End If
oStatement.close()
oDVerb.close()
Else
MsgBox("Datenquelle '" & sQuelle & "' nicht vorhanden, Programmabbruch!")
End if
End Sub
Looks like you've changed the db-handling somehow. I couldn't find any
changelog, so I asked for help in the dba.dev mailing-list.
Frank Schönheit told me to file an issue (he could reproduce the error with
MySQL over ODBC).
IDL reference says: "This exception occurs if the object behind this interface
has been disposed before and can't uphold its method specification anymore."
But oStatement still exists, so what is wrong with the new version ?
Thank you for your help, Rado
---------------------------------------------------------------------
Please do not reply to this automatically generated notification from
Issue Tracker. Please log onto the website and enter your comments.
http://qa.openoffice.org/issue_handling/project_issues.html#notification
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]