Your schema permits null or an array of records. I suspect you want an
array containing nulls or records, e.g.,

{"type":"array","items":["null",{"type":"record"...
On Jun 3, 2016 5:54 PM, "Giri P" <gpatc...@gmail.com> wrote:

> Hi,
>
> I'm getting below error when I try to insert null into union of array
>
> Caused by: org.apache.avro.UnresolvedUnionException: Not in union
> ["null",{"type":"array","items":{"type":"record","name":"DeMatchedAttr","namespace":"cp","fields":[{"name":"id","type":"long","doc":"Attribute
> id"},{"name":"updateDate","type":"long","doc":"Update date of the
> attribute"},{"name":"value","type":"string","doc":"Value of the
> attribute"}]}}]: null
>
> Is there any issue with the schema ?
>
> Thanks for the help
>
> -Giri
>

Reply via email to