[sqlalchemy] Re: bad result when querying for null values (in pk at least)

2009-10-15 Thread Mike Conley
add allow_null_pks to your mapper arguments


See
  http://www.sqlalchemy.org/docs/05/reference/orm/mapping.html

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sqlalchemy] Re: bad result when querying for null values (in pk at least)

2009-10-15 Thread alexbodn . groups

thanks a lot mike, it's working great now.

but this flag should be implied if one of the primary key fields is nullable 
(especially since it's not nullable by default).

what would you think?

On Thu, Oct 15, 2009 at 14:28, Mike Conley mconl...@gmail.com wrote:

add allow_null_pks to your mapper arguments


See
  http://www.sqlalchemy.org/docs/05/reference/orm/mapping.html

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---






--
alex



smime.p7s
Description: S/MIME Cryptographic Signature


[sqlalchemy] Re: bad result when querying for null values (in pk at least)

2009-10-15 Thread Mike Conley
On Thu, Oct 15, 2009 at 9:21 AM, alexbodn.gro...@gmail.com wrote:

 thanks a lot mike, it's working great now.

 but this flag should be implied if one of the primary key fields is
 nullable (especially since it's not nullable by default).

 what would you think?


 You can argue just as easily that the null primary key means the record is
incomplete and should not be available. It's an application code issue.

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sqlalchemy] Re: bad result when querying for null values (in pk at least)

2009-10-15 Thread King Simon-NFHD78

 -Original Message-
 From: sqlalchemy@googlegroups.com 
 [mailto:sqlalch...@googlegroups.com] On Behalf Of Mike Conley
 Sent: 15 October 2009 14:43
 To: sqlalchemy@googlegroups.com
 Cc: SQLElixir
 Subject: [sqlalchemy] Re: bad result when querying for null 
 values (in pk at least)
 
 
 On Thu, Oct 15, 2009 at 9:21 AM, alexbodn.gro...@gmail.com wrote:
 
 
   thanks a lot mike, it's working great now.
   
   but this flag should be implied if one of the primary 
 key fields is nullable (especially since it's not nullable by 
 default).
   
   what would you think?
 
 
 
 You can argue just as easily that the null primary key means 
 the record is incomplete and should not be available. It's an 
 application code issue.
  

According to http://www.sqlalchemy.org/trac/wiki/06Migration the flag
will be turned on by default in 0.6

Simon

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sqlalchemy] Re: bad result when querying for null values (in pk at least)

2009-10-15 Thread alexbodn . groups



On Thu, Oct 15, 2009 at 15:43, Mike Conley mconl...@gmail.com wrote:


On Thu, Oct 15, 2009 at 9:21 AM, alexbodn.gro...@gmail.com wrote:


thanks a lot mike, it's working great now.

but this flag should be implied if one of the primary key fields is
nullable (especially since it's not nullable by default).

what would you think?


You can argue just as easily that the null primary key means the record is
incomplete and should not be available. It's an application code issue.
 

but i'm talking about nullable=True

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---






--
alex



smime.p7s
Description: S/MIME Cryptographic Signature


[sqlalchemy] Re: bad result when querying for null values (in pk at least)

2009-10-15 Thread alexbodn . groups



On Thu, Oct 15, 2009 at 15:48, King Simon-NFHD78 simon.k...@motorola.com 
wrote:



-Original Message-
From: sqlalchemy@googlegroups.com
[mailto:sqlalch...@googlegroups.com] On Behalf Of Mike Conley
Sent: 15 October 2009 14:43
To: sqlalchemy@googlegroups.com
Cc: SQLElixir
Subject: [sqlalchemy] Re: bad result when querying for null
values (in pk at least)


On Thu, Oct 15, 2009 at 9:21 AM, alexbodn.gro...@gmail.com wrote:


      thanks a lot mike, it's working great now.

      but this flag should be implied if one of the primary
key fields is nullable (especially since it's not nullable by
default).

      what would you think?



You can argue just as easily that the null primary key means
the record is incomplete and should not be available. It's an
application code issue.



According to http://www.sqlalchemy.org/trac/wiki/06Migration the flag
will be turned on by default in 0.6

it's indeed redundant, thanks.


Simon

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---






--
alex



smime.p7s
Description: S/MIME Cryptographic Signature