Hello, I want to get the counting of sources in Gaia_dr3.gaia_source with different Healpixs, colors, and magnitudes. I run a SQL query and it runs successfully but time out. Therefore, I use async_=True to longer the query time but meets an error.
from dl import queryClient as qc
querysen='SELECT healpix_, phot_g_mean_mag_, g_rp_, COUNT(*) AS n FROM (SELECT ceiling(source_id/562949953421312) AS healpix_, ceiling(floor((phot_g_mean_mag - 8)/0.2)) AS phot_g_mean_mag_, ceiling(floor((g_rp - 0.5)/0.1)) AS g_rp_ FROM gaia_dr3.gaia_source WHERE phot_g_mean_mag > 8 AND phot_g_mean_mag < 18 AND g_rp > 0.5 AND g_rp < 1.5) AS subquery GROUP BY healpix_, phot_g_mean_mag_, g_rp_'
result = qc.query(sql=querysen,fmt='csv', async_=False)
but when I use job=qc.query(sql=querysen,fmt='csv', async_=True), I get an error with "Error: UnsupportedOperationException: sub-select not supported in FROM clause."
I find that the same error if I use adql query in result = qc.query(adql=querysen,fmt='csv', async_=False).
Therefore, If I use async_=True, I can only use adql query rather than sql query?