Enum in a dictionary

31 views
Skip to first unread message

Shohre Mansouri

unread,
Apr 2, 2013, 5:35:32 PM4/2/13
to rav...@googlegroups.com
We have store.Conventions.SaveEnumsAsIntegers = true; in our application.
And this works when we have an Enum on the entity.
But we have a dictionary that the key is an enum and RavenDb saves it as string. Is there a way to force this to save as integer too.
We are on version 1.0 build 960.

Oren Eini (Ayende Rahien)

unread,
Apr 2, 2013, 5:44:07 PM4/2/13
to ravendb
You can do that by customizing the json serializer.



--
You received this message because you are subscribed to the Google Groups "ravendb" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ravendb+u...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Oren Eini (Ayende Rahien)

unread,
Apr 2, 2013, 5:44:21 PM4/2/13
to ravendb
Note that dictionary keys must always be strings.

Shohre Mansouri

unread,
Apr 2, 2013, 5:55:10 PM4/2/13
to rav...@googlegroups.com
Thanks, we will be sticking with the behaviour as it is.
Reply all
Reply to author
Forward
0 new messages