0 votes

I'm still trying to crossmatch CatWISE2020 with VHS DR5. I have aborted my recent query because it neither times out nor it succeeds.

That's why I started with a new approach and tried to replicate the crossmatch query from one of the notebooks labeled "How to do an efficient crossmatch of a user table with a table in Data Lab" (notebooks-latest/04_HowTos/CrossmatchTables/).

My current query reads as follows:

query = '''SELECT c.*, vv.japermag3, vv.mergedclass
         FROM mydb://catwxvhs AS c
               SELECT v.ra2000, v.dec2000, v.japermag3, v.mergedclass
                        vhs_dr5.vhs_cat_v3 AS v
                        q3c_join(c.ra, c.dec, v.ra2000, v.dec2000, 0.0014)
                    ORDER BY
                        q3c_dist(c.ra, c.dec, v.ra2000, v.dec2000)
                    ASC LIMIT 1
               ) as vv ON true'''

Even though it's nearly the same query from the notebook, it unfortunately results in an error message and I've got no clue why that is. The error message says:

Retrieving error
Error: IllegalArgumentException: net.sf.jsqlparser.JSQLParserException JSQLParserException:  ParseException: Encountered "vv" at line 1, column 12.
Was expecting one of:
    <S_INTEGER> ...
    "?" ..

What have I done wrong? Why does the "vv" seem to be the problem? The original query uses "gg" for the outer part and "g" in the inner part. I just switched that to "vv" and "v".

asked Aug 24 by martinkb (520 points)
edited Aug 24 by martinkb | 23 views

2 Answers

0 votes
Is the missing 'SELECT' at the start of your query a cut-n-paste issue or is it really missing?
answered Aug 24 by datalab (17,680 points)
A bit of both. I wrongly copy&pasted from my notebook but 'SELECT' was also missing in my last attempt in the notebook. The "SELECT" has been there though in previous attempts and I also added it now back in but the error reads still the same.
0 votes
By the way, I also tried it with a synchronous query yesterday but had no luck. It times out after 600 seconds. It didn't have any problems with the 'INNER JOIN LATERAL' though.

Is this maybe another ADQL parser bug?
answered Aug 25 by martinkb (520 points)

337 questions

351 answers


2,277 users

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