summaryrefslogtreecommitdiff
path: root/odb/oracle/simple-object-result.txx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2014-11-26 10:58:50 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2014-11-26 10:58:50 +0200
commit76a03fd7964b85cdc1a903df79bfd47711c720e9 (patch)
tree4c73f15b891746990b62e9a33b75c7feb2989b8d /odb/oracle/simple-object-result.txx
parent7a3b76479162e3e3fe6c425f7bb20eaea8f41e17 (diff)
Reimplement image copying for Oracle
Now we no longer "steal" descriptors (destructive copy). Instead, for LOBs, we clone the locator using OCILobAssign(). For date-time types we extract the data during copying. As a result of this change we no longer need to track image changes and rebind the statements.
Diffstat (limited to 'odb/oracle/simple-object-result.txx')
-rw-r--r--odb/oracle/simple-object-result.txx15
1 files changed, 1 insertions, 14 deletions
diff --git a/odb/oracle/simple-object-result.txx b/odb/oracle/simple-object-result.txx
index 114c919..ed16c55 100644
--- a/odb/oracle/simple-object-result.txx
+++ b/odb/oracle/simple-object-result.txx
@@ -163,7 +163,7 @@ namespace odb
template <typename T>
void object_result_impl<T>::
- change_callback (void* c, binding* b)
+ change_callback (void* c)
{
object_result_impl<T>* r (static_cast<object_result_impl<T>*> (c));
typename object_traits::image_type& im (r->statements_.image ());
@@ -173,19 +173,6 @@ namespace odb
else
*r->image_copy_ = im;
- // Increment image version since we may have "stolen" descriptors
- // (LOB, date-time) from the image. This will trigger re-bind which
- // will reallocate them and update the binding. In case this callback
- // was triggeted as part of a select statement fetch, then it is too
- // late to update the image version and we also need to update the
- // image binding.
- //
- // @@ Would be good to only do this if we actually have descriptors.
- //
- im.version++;
- if (b != 0)
- b->version++;
-
im.change_callback_.callback = 0;
im.change_callback_.context = 0;