Gaia Archive arrays implementation

Gregory Mantelet gmantele at ari.uni-heidelberg.de
Mon Aug 28 10:26:54 CEST 2017


Hi Juan, DAL,

I also agree with Mark on this point. Specifying array indices inside a 
string increases the risk of a typo by a user and makes the writing of 
an ADQL query a bit more painful, in addition of making the parsing a 
bit more complex.

Is there a particular reason why this solution has been chosen?

As agreed, I will implement array manipulation functions as they are 
specified by ESA, but I would much appreciate the syntax suggested by Mark:

     get_double_array_element('{{1.0,2.6},{0.8,0.1}}', 1, 2)

and

     get_double_array_element('{1.0,2.6}', 1)

Grégory


On 25/08/2017 11:23, Mark Taylor wrote:
> Juan Carlos,
>
> On Mon, 21 Aug 2017, Juan Carlos Segovia wrote:
>
>> This mail is to explain how arrays are going to be handled in the Gaia archive
>> TAP service for DR2.
> thanks for summarising this here.  IMHO what you've outlined sounds
> reasonable until TAP 1.1 is more stable and supported.
>
> One point:
>
>> SELECT get_double_array_element('{{1.0,2.6},{0.8,0.1}}','[1][2]') from
> Have you considered a  more straightforward syntax like
>
>     get_double_array_element('{{1.0,2.6},{0.8,0.1}}', 1, 2)
>
> which could be overloaded with variable numbers of integer index
> arguments like:
>
>     get_double_array_element('{1.0,2.6}', 1)
>
> The string syntax is more unwieldy to use, especially if you want
> to index with a variable, and also in view of the fact that as I
> understand it most of the arrays in this DB will be 1-dimensional
> (Alcione's comment in C9GACS-235 "No other two index arrays in DR2
> (to my knowledge)" [apart from the 6x6 form of the covariance]).
>
> But, this is an implementation detail so if ESDC want to do it that
> way it's up to you.
>
> Mark
>
> --
> Mark Taylor   Astronomical Programmer   Physics, Bristol University, UK
> m.b.taylor at bris.ac.uk +44-117-9288776  http://www.star.bris.ac.uk/~mbt/




More information about the dal mailing list