next up previous 89
Next: Linked configuration files
Up: Carrying On
Previous: Multiple catalogue servers

Providing range queries

As well as selecting objects in a circular area of sky it is possible to further restrict the objects selected to only those for which the values of some column lie within a given range. Suppose selections from an optical catalogue were to be optionally restricted to also lie within a specified range of magnitudes and the column of magnitudes was named mag. To provide this facility for a catalogue its entry in the configuration file should be include the keyword search_cols and the query part of its url keyword should include the token %cond.

  1. The syntax of the search_cols keyword is:

    search_cols: column-name minimum-prompt maximum-prompt

    For example:

    search_cols: mag "Bright limit" "Faint limit"

    column-name is the name of the column. The client uses minimum-prompt and maximum-prompt as prompts when soliciting the extrema of the required range from the user. (Note that because the example column is a magnitude the ``Bright limit" corresponds to the smallest numerical value and the ``Faint limit" to the largest.)

  2. The %cond token is added to the query part of the url keyword to supply details of the range query. Such a query string might look like:

    ra=%ra&dec=%dec&radius=%r2&%cond

    The syntax of the values substituted into the %cond string is:

    column-name = minimum-value,maximum-value

    For example, if a range of first to second magnitude had been specified for column mag then %cond would translate to:

    mag=1.0,2.0

    The server that parses the query must interpret this string and ensure that the range selection specified is applied.

See Section [*] for further details.


next up previous 89
Next: Linked configuration files
Up: Carrying On
Previous: Multiple catalogue servers

Writing Catalogue and Image Servers for GAIA and CURSA
Starlink System Note 75
A.C. Davenhall
26 July 2000
E-mail:ussc@star.rl.ac.uk

Copyright © 2000 Council for the Central Laboratory of the Research Councils