Glorp: problem with DictionaryMapping with "data objects"

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Glorp: problem with DictionaryMapping with "data objects"

Herby Vojčík
Hello!

I have the problem with mapping dictionary of key to simple data-holding
object (two integers) work. Glorp DictionaryMapping dicriminates between
mapping a simple value (#dictionaryFrom: String to: Integer), where
things work as assumed (having two fields in a table, one for key, one
for value; and of course one for FK to owner) and mapping an object
(#dictionaryFrom: String to: MyClass), where it fails miserably if the
object does not contain the key itself as the FK as well (which is dumb;
I want it unidirectional). In case I do not include the key-as-FK, it
fails to grasp update and/or deletes, and fails during commit with
either UNIQUE failure (when update is interpreted as insert) or with
NULL failure (where delete is interpreted as insert with nil in place of
dict key field).

Maybe it is a missing feature in DictionaryMapping; maybe I am doing
something wrong. I would like to ask if there isn't someone currently on
ESUG who would want a bit of more sightseeing and would be willing to
get a detour via Bratislava (I have a place for stayover) and look at
the issue face to face (or I can use ScreenHero, but as I understood it
does not have Linux client, maybe that's why Esteban did not accept my
invitation yet).

Thanks, Herby

--
You received this message because you are subscribed to the Google Groups "glorp-group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/glorp-group.
For more options, visit https://groups.google.com/d/optout.