ObsCore Examples from Heidelberg

These are examples for ADQL you can run in TAP services carrying an ivoa.obscore table. See ObsCore for the underlying data model.

Finding images by time and place

Suppose you read in an old amateur observer's log there was an unexpected object on the night sky in the cold winter nights of the week between January 12th and 18th, 1903 – and now you would like to see whether there could be an observation of such a thing.

SELECT s_ra, s_dec, t_min FROM ivoa.obscore
  WHERE t_min BETWEEN gavo_to_mjd('1903-01-12')
      AND gavo_to_mjd('1903-01-19')

There is also a shortcut via user defined functions. As an extension to regular ADQL, DaCHS lets you write gavo_simbadpoint('object') and replaces the result with a position obtained from simbad, like this:

SELECT access_url, t_exptime, t_min FROM ivoa.obscore
  WHERE
    t_min BETWEEN gavo_to_mjd('J2416128.5')
      AND gavo_to_mjd('J2416133.5') AND
    1=CONTAINS(gavo_simbadpoint('Aldebaran'),
      CIRCLE('ICRS', s_ra, s_dec, 15))