Many thanks for the answer.

Another hopefully quick question:  

Is it possible to select a subset of columns in a query of an Entity
subclass?  Kind of 

EntitySubClass.query.select([EntitySubClass.c.col1,
                             EntitySubClass.c.col2]).all()

best cheers
-b 

On Fri, 28 Mar 2008 14:51:24 -0400
Jonathan LaCour <[EMAIL PROTECTED]> wrote:

> 
> Bud P. Bruegger wrote:
> 
> > I have one remaining problem though:  I would like to set the
> > properties of my Entity classes (that inherit from Entity or a
> > custom base class) programatically using "has_field".
> 
> Not using `has_field`, but you *can* do it programmatically:
> 
>      class Person(Entity):
>          pass
> 
>      name_field = Field(String(64))
>      name_field.attach(Person, 'name')
> 
>      setup_all()
> 
> You could easily create a utility function that walked through some
> sort of "spec" like you've defined to attach fields in this manner
> to your entities, although I am not sure why you'd want to do it
> this way :)
> 
> --
> Jonathan LaCour
> http://cleverdevil.org
> 
> > 


-- 
Bud P. Bruegger, Ph.D.          +39-0564-488577 (voice),  -21139 (fax) 
   European Chair, Global Collaboration Forum on eID
   Chair, Porvoo Subgroup on collab. govs/operating systems
   Leader of the Permanent eID Status Observatory (PESO) project
Servizio Elaborazione Dati       e-mail:  [EMAIL PROTECTED]
Comune di Grosseto               jabber:  [EMAIL PROTECTED]
Via Ginori, 43                   http://www.comune.grosseto.it/
58100 Grosseto (Tuscany, Italy)
http://www.comune.grosseto.it/interopEID/

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"SQLElixir" 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/sqlelixir?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to