title: Azure Data Factory ADF Schema validation for JSON
body: <p>I am implementing a feature which is validating a dataset schema.
  I know that in ADF there is a checkbox in the Mapping Dataflow section which does it automatically if columns or type of the column does not match against the reference.
  For CSV it works fine for me, but in case of JSON I noticed two thing:
  1, when I created a Dataset for the JSON its schema is different what I see in the Mapping Dataflow although I use the same dataset. I tried every option at both (Dataset &amp; Data Flow) places import from sample file, import projection etc.. w/o success</p>
  <p><img src="https://i.stack.imgur.com/nfolh.png" alt="sameDataSetDifferentSchema.png" /></p>
  <p>At the end in the Dataset I changed it manually in the code part by editing the JSON's JSON :)</p>
  <p><img src="https://i.stack.imgur.com/9nQuT.png" alt="changeSchemaOfDataset.png" /></p>
  <p>2, lastly it does not solved the problem after having the same Schema it is still failing during schema validation.</p>
  <p><img src="https://i.stack.imgur.com/Z89il.png" alt="ErrorMsg.png" /></p>
  <p>However in the error msg itself it dispalys the same type if you see the screenshot:</p>
  <p>Found: <code>ArrayType(StructType(StructField(**Description1**,StringType,true),...etc</code>
  Required: <code>ArrayType(StructType(StructField(**Description1**,StringType,true),...etc</code></p>