OK it works (not yet in tip though).

On Dec 8, 2011, at 11:43 AM, Michael Bayer wrote:

> the recipe is broken, please wait until i have time to fix it, thanks.
> 
> 
> On Dec 8, 2011, at 11:27 AM, Michael Bayer wrote:
> 
>> 
>> On Dec 7, 2011, at 11:08 PM, kris wrote:
>> 
>>> Hmm, I think I want the opposite behavior.  I was the defualt mapper to 
>>> Resource unless a more specific mapper has been defined.
>>> I never defined a 'C' or 'D' and I would like simple get a Resource when no 
>>> better mapper is found. 
>>> i.e. I get Resource class for C, D and get a Resource_A for A and a 
>>> Resource_B for B.  
>>> 
>>> Is this possible?
>> 
>> So you're looking for a row that has "C" or "D" in it to act as though it 
>> were "default".    As an easy feature, that is ticket #2238 set on the 0.8 
>> milestone.
>> 
>> the workaround for now is to use column_property() in conjunction with a 
>> case() statement, I've posted the recipe for that at 
>> http://www.sqlalchemy.org/trac/wiki/UsageRecipes/CaseBasedPolymorphicOn .
>> 
>> It will work in 0.7.3 but not in the current tip as there is a bug 
>> preventing it from working.
>> 
>> 
>> 
>>> 
>>> -- 
>>> You received this message because you are subscribed to the Google Groups 
>>> "sqlalchemy" group.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msg/sqlalchemy/-/FHmjireFL_EJ.
>>> To post to this group, send email to sqlalchemy@googlegroups.com.
>>> To unsubscribe from this group, send email to 
>>> sqlalchemy+unsubscr...@googlegroups.com.
>>> For more options, visit this group at 
>>> http://groups.google.com/group/sqlalchemy?hl=en.
>> 
>> 
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "sqlalchemy" group.
>> To post to this group, send email to sqlalchemy@googlegroups.com.
>> To unsubscribe from this group, send email to 
>> sqlalchemy+unsubscr...@googlegroups.com.
>> For more options, visit this group at 
>> http://groups.google.com/group/sqlalchemy?hl=en.
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "sqlalchemy" group.
> To post to this group, send email to sqlalchemy@googlegroups.com.
> To unsubscribe from this group, send email to 
> sqlalchemy+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/sqlalchemy?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to sqlalchemy@googlegroups.com.
To unsubscribe from this group, send email to 
sqlalchemy+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en.

Reply via email to