Re: Checking if a ForeignKey field is NULL

2009-07-04 Thread Alex Gaynor
On Sat, Jul 4, 2009 at 1:33 PM, Ryan K wrote: > > Lets say I retrieve from my database an object foo and foo's model has > a ForeignKey field, baz, with null and blank set to True. Will a > simple test like if foo.baz ... test whether the field is set to NULL > or not? > > Cheers, > Ryan > > > Ye

Checking if a ForeignKey field is NULL

2009-07-04 Thread Ryan K
Lets say I retrieve from my database an object foo and foo's model has a ForeignKey field, baz, with null and blank set to True. Will a simple test like if foo.baz ... test whether the field is set to NULL or not? Cheers, Ryan --~--~-~--~~~---~--~~ You received thi