Registry query language

Tony Linde ael at star.le.ac.uk
Tue Sep 23 11:18:41 PDT 2003


I must admit that I couldn't answer that but I think the point is not what
the query would look like to the user - the user will not be writing such a
query. They will be selecting what they want from some sort of interface and
the program behind that will construct the query to send to the registry. In
this case XQuery has an advantage as it can more directly access and return
the xml-based resource metadata.

Cheers,
Tony. 

> -----Original Message-----
> From: owner-registry at eso.org [mailto:owner-registry at eso.org] 
> On Behalf Of Thomas McGlynn
> Sent: 23 September 2003 18:59
> To: Elizabeth Auden
> Cc: registry at ivoa.net
> Subject: Re: Registry query language
> 
> 
> Elizabeth Auden wrote:
> 
> >>What form should the registry query language take?
> >>1. an xml form of SQL (as for ADQL in the SkyNode document) 
> 2. Xquery
> > 
> > 
> > My choice would be XQuery - I think it has more recent W3C 
> standards 
> > than any of the SQL implementations, and XQuery also has 
> the benefit 
> > of internet support and documentations from many projects 
> on the web, 
> > not just VOs.
> > 
> > cheers,
> > Elizabeth
> > 
> > 
> 
> This is one of the many cases where I'm not sure I know 
> enough to make an intelligent choice.  I can understand how 
> to write SQL (or some XML-parsed version of it) to do the 
> kinds of queries that I might want for a registry, but I 
> don't have the sense of what these might look like in 
> XQquery.  Here are a couple of example queries in pseudo-SQL. 
>  Could someone suggest what they might look like in Xquery?
> 
> 	Tom
> 
> In these pseudo-SQL I'm assuming there is a single 'registry' 
> table that includes both DataCollection entries and service 
> entries and that the linking fields discussed in the telecon 
> today between data collections and services exists (and is 
> saved as a concatentation of the collection id strings)
> 
> 
> A very simplified version of what the DIS service does..
> 
>      select service_name, short_name, curator, instrument  
> from registry  where
>           type='Catalog' and service_type='Cone'
> 
> 
> A query for services that can access any existing database of 
> X-ray information where the collection has resolution > 1' 
> and the service has an SIA interface
> 
>      select services.service_name from registry services, 
> registry collections
>             where collection.spectral_regime = 'X-ray' and
>                   collection.spatial_resolution < 1/60. and
>                   collection.service_type = 'DataCollection' and
>                   registry.linked_resources like '% 
> '+databases.id+' %'
>                   registry.service_type like 'SIA/%'
> 
> Find the data collections that are not linked to any services.
> 
>     select collections.service_name from registry collections
>                        where not exists
>                          (select services.service_name from 
> registry services
>                                  where 
> services.linked_resources like '% '+databases.id +' %')
> 
> (In practice I'd implement the linked resources as a join 
> table, rather than concatentating them in a single element of 
> the registry table, but I hope this gives the sense of what 
> I'm asking for.)
> 
> 
> 
> 




More information about the registry mailing list