On Oct 13, 2011, at 8:55 AM, Sean Kelly wrote: >>> DIS-style query2: >>> prod?q=RETURN = mrn AND RETURN = birth_dt_tm AND loc_nurse_unit_cd_desc_1 = >>> 'PICU' OR loc_nurse_unit_cd_desc_1 = 'PICU2' >> >> This isn't a valid DIS-tyle query. Note that you can't do RETURN = a *AND* >> b. It's RETURN = a AND RETURN = b. > > I think it is valid. The constraint is "loc_nurse_unit_cd_desc_1 = 'PICU' OR > loc_nurse_unit_cd_desc_1 = 'PICU2'" and the range is "mrn" and "birth_dt_tm". > > We usually write all the RETURNs at the end: > > loc_nurse_unit_cd_desc_1 = 'PICU' OR loc_nurse_unit_cd_desc_1 = 'PICU2' > AND RETURN = mrn AND RETURN = birth_dt_tm > > But if I remember how the parser works, it doesn't matter where the RETURNs > appear, or what conjunctive is used to attach them in. Or, at least, it > shouldn't. (We have a bug?)
Good question; for whatever reason I was parsing the above as RETURN = a *AND* b when in fact it's RETURN = a *AND* b = c. That *is* valid, yes. Cheers, Chris ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Chris Mattmann, Ph.D. Senior Computer Scientist NASA Jet Propulsion Laboratory Pasadena, CA 91109 USA Office: 171-266B, Mailstop: 171-246 Email: [email protected] WWW: http://sunset.usc.edu/~mattmann/ ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Adjunct Assistant Professor, Computer Science Department University of Southern California, Los Angeles, CA 90089 USA ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
