Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ SQL » Oracle RefCursor and Stored Procedure
Re: Oracle RefCursor and Stored Procedure [message #42996 is a reply to message #42994] Tue, 22 April 2014 14:28 Go to previous messageGo to previous message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
aksdb wrote on Tue, 22 April 2014 09:26
I was wrong: RawToValue is necessary. However something is wrong there.

I added some debug output to "void OCI8Connection::SetParam(int i, const Value& q)":
Cout() << Format("Type is 0x%X (%s)", (int)q.GetType(), q.GetTypeName()) << EOL;


This results in:
Type is 0x8000000 (N3Upp11RawValueRepIPNS_3SqlEEE)


Obviously, this means that type is != UNKNOWN_V, so we run into the assertion "NEVER();".

Just for the sake of testing it, I moved the relevant check (if(IsTypeRaw<Sql *>(q)) ...) into the default case. This will at least make the Oracle call succeed and I also get a result set I can iterate on, however when the application closes, I get a report about a heap corruption:
Heap is corrupted --memory-breakpoint__ 1189


Something's very wrong here, I'm afraid.


Removing case UNKNOWN_V is absolutely correct; it looks like nobody ever used this code snippet for a very long time.
Personally, I am only using Oci7 part of Oracle package. Change is now commited.

It is also possible that the heap corruption was there since the day one, only that it now gets detected:)

However, is not it possible that the heap corruption is somehow caused by your app? If it is simple test, can you post it here?

Mirek

[Updated on: Tue, 22 April 2014 14:29]

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Schema description documentation not matching code behavior
Next Topic: PATCH: SqlSelect::ForUpdate() should generate nothing for SQLITE3
Goto Forum:
  


Current Time: Tue May 07 09:28:43 CEST 2024

Total time taken to generate the page: 0.02565 seconds