[sqlalchemy] What is scalar-holding attribute?

2014-02-10 Thread Bao Niu
Could someone help give a simple definition of scalar-holding attribute? In
documentation for many to one relationship this term occurred, I tried
Google the term but didn't find a definition. Thx.

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


Re: [sqlalchemy] What is scalar-holding attribute?

2014-02-10 Thread Michael Bayer
a scalar is a value that is just one thing, as opposed to a collection.

e.g.:

x = 5   # — scalar

x = [1, 2, 3]  # — not a scalar

x = MyObject()   # — scalar object (SQLA distinguishes here between object and 
non…depending on what doc you’re looking at)

x = set([MyObject(), MyObject()])  # — not a scalar




On Feb 10, 2014, at 4:54 AM, Bao Niu niuba...@gmail.com wrote:

 Could someone help give a simple definition of scalar-holding attribute? In 
 documentation for many to one relationship this term occurred, I tried Google 
 the term but didn't find a definition. Thx.
 
 
 -- 
 You received this message because you are subscribed to the Google Groups 
 sqlalchemy group.
 To unsubscribe from this group and stop receiving emails from it, send an 
 email to sqlalchemy+unsubscr...@googlegroups.com.
 To post to this group, send email to sqlalchemy@googlegroups.com.
 Visit this group at http://groups.google.com/group/sqlalchemy.
 For more options, visit https://groups.google.com/groups/opt_out.



signature.asc
Description: Message signed with OpenPGP using GPGMail