Spark SQL : Handling schema evolution -


i want read 2 avro files of same data set schema evolution

  1. first avro file schema : {string, string, int}
  2. second avro file schema evolution : {string, string, long}

(int field undergone evolution long) want read these 2 avro file store in dataframe using sparksql.

to read avro files using 'spark-avro' of databicks https://github.com/databricks/spark-avro

how efficiently.

spark version : 2.0.1 scala. 2.11.8

ps. here in example have mentioned 2 files in actual scenario file generated daily there more 1000 such file.

thank in advance:)

use union like

{string,string, [int, long]}  

is valid solution your? should allow read both new , old files.


Comments

Popular posts from this blog

networking - Vagrant-provisioned VirtualBox VM is not reachable from Ubuntu host -

c# - ASP.NET Core - There is already an object named 'AspNetRoles' in the database -

ruby on rails - ArgumentError: Missing host to link to! Please provide the :host parameter, set default_url_options[:host], or set :only_path to true -