Github user tomatophantastico commented on the issue:

    https://github.com/apache/metamodel/pull/163
  
    To me, there are two use cases / requirements here:
    
    1. Make queries transferable
    2. Ease of exploring a schema and its data via SQL
    
    w.r.t 1)
    Yes, i think the data contexts are the place where this should be 
implemented. As most (all?) non-jdbc datacontexts are extending 
QueryPostProcessingContext, this could perhaps be done without too many changes.
    
    i generally think it is not a good idea to deal with a table 
"Backup_23423_hash_by_Jörg_do_not_modify.csv" in the query, especially if it 
is an export of the lets say person table. Having an alias would clear up the 
semantics of the query.
    
    "select * from person" will work on the source system, "select * from 
tables[0]" not. 
    
    
    w.r.t. 2)
    Just iterating over tables without having the table name, does not really 
make sense to me. How should the result of such a query look like?
    
    Most DBMs implement this via custom commands (list tables/documents...) or 
using tables (SELECT table_schema,table_name FROM information_schema.tables).
    
    Maybe we can cook up sth. more convenient here. But i would prefer to 
change the semantics of SQL.
    
    
    
    



---

Reply via email to