sijocherian / google-bigquery

Automatically exported from code.google.com/p/google-bigquery
0 stars 0 forks source link

Allow referencing the tableName in the SELECT statements when running a table Query #163

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Example:

SELECT count(*), table_id FROM TABLE_QUERY(myDataset, 'table_id CONTAINS 
"_201410_"');

or perhaps:

SELECT count(*), tq.table_id FROM TABLE_QUERY(myDataset, 'table_id CONTAINS 
"_201410_"') as tq;

preferably in a way so that I can strip of the "_201410_" part in a function or 
use it in a group by.

Original issue reported on code.google.com by sjuul.ja...@transceptor-technology.com on 7 Oct 2014 at 1:49

GoogleCodeExporter commented 9 years ago
This would be a great feature to have.  I have instances of data being sharded 
daily, and would like to get table name instead of storing the relatively 
redundant information within the table itself (since the table name already has 
the date).  

Original comment by wls...@motorola.com on 20 Jul 2015 at 5:59