rqlrewrite.py
branchstable
changeset 5704 924ea48326c4
parent 5582 3e133b29a1a4
child 5992 5f9a9086c171
equal deleted inserted replaced
5703:24ca7615379b 5704:924ea48326c4
   351                 if rschema.inlined and rel.optional:
   351                 if rschema.inlined and rel.optional:
   352                     need_null_test = True
   352                     need_null_test = True
   353         if need_null_test:
   353         if need_null_test:
   354             snippetrqlst = n.Or(
   354             snippetrqlst = n.Or(
   355                 n.make_relation(subselectvar, 'is', (None, None), n.Constant,
   355                 n.make_relation(subselectvar, 'is', (None, None), n.Constant,
   356                                 operator='IS'),
   356                                 operator='='),
   357                 snippetrqlst)
   357                 snippetrqlst)
   358         subselect.add_restriction(snippetrqlst)
   358         subselect.add_restriction(snippetrqlst)
   359         if self.u_varname:
   359         if self.u_varname:
   360             # generate an identifier for the substitution
   360             # generate an identifier for the substitution
   361             argname = subselect.allocate_varname()
   361             argname = subselect.allocate_varname()