Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I have a Spark Job with a Hive query that reads an external table (JSON format), but when i tried to get the colonne INPUT__FILE__NAME i have this error :
hive org.apache.spark.sql.AnalysisException: cannot resolve '`INPUT__FILE__NAME`'
My job
tHiveInput -> tMap -> tHiveOutput
How can i get the file name ?
My config:
Talend Big Data Batch Platform 6.5.1
Cloudera 5.12
Thanks
smer
The solution is that "input__file_name" is a virtual hive collumn, i just use the spark's function input_file_name() and that's it
use the row name row1.filename
If filename is in tmap you need to use row2.filename
The solution is that "input__file_name" is a virtual hive collumn, i just use the spark's function input_file_name() and that's it