> anyway, the upcoming release has the framework in place to address
> this, which allows that different kinds of comparison operations
> occur for different kinds of types.  for an object attribute that
> points to a related user-defined entity, using "is" is the better
> choice rather than '==' since identity is what matters in that case.
> but for unicodes and strings too, '==' is more approrpriate.  so i
> added a test case for this scenario as well as a modified compairson
> for String/Unicode types in rev 1995.


Hi,
One of my column contains pickled objects which have a  __cmp__ method
(but no __eq__) a little bit weird: id doesn't compare anything, but
allways raises a exception. This object comes from another library
(it's actually a sparse matrix from scipy), so there's allmost nothing
I can do to change this weird behavior.
Anyway, despite they are user-defined entities, It seems that
sqlalchemy tests for equality rather than for identity since the
__cmp__ is always called, and thus exception always raised.

Any solution to avoid the exception ?

Jean-Philippe


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/sqlalchemy
-~----------~----~----~----~------~----~------~--~---

Reply via email to