0 votes
187 views
by datalab (20.7k points) | 187 views

1 Answer

0 votes

In general, no.  This is because unless the query is written in a very general way the different column names (e.g. 'ra' vs 'ra_j2000' or 'g' vs 'gmag' vs 'mag_g') would mean the SQL may not be applicable to a particular table and would generate an error.

It is, however, possible to use the tap_schema.tables and tap_schema.columns tables to automatically discover the names of tables and columns in the system.  With this information, you could create a list in your Jupyter notebook or application that could fill out a template query string in a way that lets you substitute the columns names appropriate for that table.  You could then loop over the list of tables to submit the queries individually and save the results of each.  Note that merging the results (i.e. concatenating rows of the tables) should also take into account the differing column names.

by datalab (20.7k points)

420 questions

437 answers

441 comments

638 users

Welcome to Data Lab Help Desk, where you can ask questions and receive answers from other members of the community.

Categories