title: How to normalize a json file to pandas dataframe?
body: <p>I have a json file like as shown below. I already tried the solutions from this <a href="https://stackoverflow.com/questions/27240982/valueerror-when-using-pandas-read-json">post</a>,<a href="https://www.gitmemory.com/issue/iphysresearch/TOP250movie_douban/2/487555405" rel="nofollow noreferrer">post</a></p>
  <pre><code>[{
      &quot;answersData&quot;: {
          &quot;employeeId&quot;: &quot;0923a&quot;,
          &quot;answers&quot;: {
              &quot;Address_2&quot;: &quot;Address_Line_2_1&quot;,
              &quot;Address_2_CC&quot;: &quot;Address_2_CC_1&quot;,
              &quot;CellphoneNumberConsent&quot;: &quot;YES&quot;,
              &quot;Consent_Given&quot;: &quot;Y&quot;,
              &quot;DoB&quot;: &quot;1971-07-10T16:00:00.000Z&quot;,
              &quot;EmailaddressConsent&quot;: &quot;NotApplicable&quot;,
              &quot;First_Name&quot;: &quot;First_Name_1&quot;,
              &quot;Gender&quot;: &quot;M&quot;,
              &quot;Last_Name&quot;: &quot;Last_Name_1&quot;,
              &quot;Middle_Name&quot;: null,
              &quot;PrimaryLanguage&quot;: [
                  &quot;English&quot;
              ],
              &quot;SecondaryLanguage&quot;: [
                  &quot;Hindi&quot;
              ],
              &quot;addionalIdentificationType&quot;: &quot;NO&quot;,
              &quot;cellphoneNumber&quot;: &quot;1234567890&quot;,
              &quot;countryName&quot;: &quot;IND&quot;,
              &quot;householdResponsibility&quot;: &quot;husband&quot;,
              &quot;poorCardHas&quot;: &quot;N&quot;,
              &quot;poorCardReason&quot;: &quot;OTH&quot;,
              &quot;postalCode&quot;: &quot;123456&quot;,
              &quot;profilePicture&quot;: null,
              &quot;provinceCity&quot;: &quot;Province_1&quot;
          },
          &quot;createdBy&quot;: &quot;MAM_1@123.com&quot;,
          &quot;dateCreated&quot;: &quot;2021-02-23T17:20:33.134Z&quot;,
          &quot;type&quot;: &quot;profile&quot;
      }
  }, {
      &quot;answersData&quot;: {
          &quot;employeeId&quot;: &quot;27l23t&quot;,
          &quot;answers&quot;: {
              &quot;Address_2&quot;: &quot;Address_Line_2_2&quot;,
              &quot;Address_2_CC&quot;: &quot;Address_2_CC_2&quot;,
              &quot;CellphoneNumberConsent&quot;: &quot;YES&quot;,
              &quot;Consent_Given&quot;: &quot;Y&quot;,
              &quot;DoB&quot;: &quot;1980-07-10T16:00:00.000Z&quot;,
              &quot;EmailaddressConsent&quot;: &quot;NotApplicable&quot;,
              &quot;First_Name&quot;: &quot;First_Name_2&quot;,
              &quot;Gender&quot;: &quot;M&quot;,
              &quot;Last_Name&quot;: &quot;Last_Name_2&quot;,
              &quot;Middle_Name&quot;: null,
              &quot;PrimaryLanguage&quot;: [
                  &quot;English&quot;
              ],
              &quot;SecondaryLanguage&quot;: [
                  &quot;Kannada&quot;
              ],
              &quot;addionalIdentificationType&quot;: &quot;NO&quot;,
              &quot;cellphoneNumber&quot;: &quot;1234567890&quot;,
              &quot;countryName&quot;: &quot;IND&quot;,
              &quot;householdResponsibility&quot;: &quot;wife&quot;,
              &quot;poorCardHas&quot;: &quot;N&quot;,
              &quot;poorCardReason&quot;: &quot;OTH&quot;,
              &quot;postalCode&quot;: &quot;621&quot;,
              &quot;profilePicture&quot;: null,
              &quot;provinceCity&quot;: &quot;Province_2&quot;
          },
          &quot;createdBy&quot;: &quot;MAM_2@123.com&quot;,
          &quot;dateCreated&quot;: &quot;2021-02-23T17:20:33.134Z&quot;,
          &quot;type&quot;: &quot;profile&quot;
      }
  }, {
      &quot;answersData&quot;: {
          &quot;employeeId&quot;: &quot;290p&quot;,
          &quot;answers&quot;: {
              &quot;Address_2&quot;: &quot;Address_Line_2_3&quot;,
              &quot;Address_2_CC&quot;: &quot;Address_2_CC_3&quot;,
              &quot;CellphoneNumberConsent&quot;: &quot;NO&quot;,
              &quot;Consent_Given&quot;: &quot;N&quot;,
              &quot;DoB&quot;: &quot;1991-10-10T16:00:00.000Z&quot;,
              &quot;EmailaddressConsent&quot;: &quot;NotApplicable&quot;,
              &quot;First_Name&quot;: &quot;First_Name_3&quot;,
              &quot;Gender&quot;: &quot;M&quot;,
              &quot;Last_Name&quot;: &quot;Last_Name_3&quot;,
              &quot;Middle_Name&quot;: null,
              &quot;PrimaryLanguage&quot;: [
                  &quot;German&quot;
              ],
              &quot;SecondaryLanguage&quot;: [
                  &quot;Telugu&quot;
              ],
              &quot;addionalIdentificationType&quot;: &quot;NO&quot;,
              &quot;cellphoneNumber&quot;: &quot;1234567890&quot;,
              &quot;countryName&quot;: &quot;IND&quot;,
              &quot;householdResponsibility&quot;: &quot;Father&quot;,
              &quot;poorCardHas&quot;: &quot;N&quot;,
              &quot;poorCardReason&quot;: &quot;OTH&quot;,
              &quot;postalCode&quot;: &quot;123456&quot;,
              &quot;profilePicture&quot;: null,
              &quot;provinceCity&quot;: &quot;Province_3&quot;
          },
          &quot;createdBy&quot;: &quot;MAM_3@123.com&quot;,
          &quot;dateCreated&quot;: &quot;2021-01-11T19:11:20.134Z&quot;,
          &quot;type&quot;: &quot;profile&quot;
      }
  }, {
      &quot;answersData&quot;: {
          &quot;employeeId&quot;: &quot;17mk9i&quot;,
          &quot;answers&quot;: {
              &quot;Address_2&quot;: &quot;Address_Line_2_4&quot;,
              &quot;Address_2_CC&quot;: &quot;Address_2_CC_4&quot;,
              &quot;CellphoneNumberConsent&quot;: &quot;YES&quot;,
              &quot;Consent_Given&quot;: &quot;Y&quot;,
              &quot;DoB&quot;: &quot;1947-07-10T16:00:00.000Z&quot;,
              &quot;EmailaddressConsent&quot;: &quot;NotApplicable&quot;,
              &quot;First_Name&quot;: &quot;First_Name_4&quot;,
              &quot;Gender&quot;: &quot;M&quot;,
              &quot;Last_Name&quot;: &quot;Last_Name_4&quot;,
              &quot;Middle_Name&quot;: null,
              &quot;PrimaryLanguage&quot;: [
                  &quot;English&quot;
              ],
              &quot;SecondaryLanguage&quot;: [
                  &quot;Hindi&quot;
              ],
              &quot;addionalIdentificationType&quot;: &quot;NO&quot;,
              &quot;cellphoneNumber&quot;: &quot;1234567890&quot;,
              &quot;countryName&quot;: &quot;IND&quot;,
              &quot;householdResponsibility&quot;: &quot;mother&quot;,
              &quot;poorCardHas&quot;: &quot;N&quot;,
              &quot;poorCardReason&quot;: &quot;OTH&quot;,
              &quot;postalCode&quot;: &quot;123456&quot;,
              &quot;profilePicture&quot;: null,
              &quot;provinceCity&quot;: &quot;Province_4&quot;
          },
          &quot;createdBy&quot;: &quot;MAM_4@123.com&quot;,
          &quot;dateCreated&quot;: &quot;2021-05-23T17:20:33.134Z&quot;,
          &quot;type&quot;: &quot;profile&quot;
      }
  }, {
      &quot;answersData&quot;: {
          &quot;employeeId&quot;: &quot;17lo8i&quot;,
          &quot;answers&quot;: {
              &quot;Address_2&quot;: &quot;Address_Line_2_5&quot;,
              &quot;Address_2_CC&quot;: &quot;Address_2_CC_5&quot;,
              &quot;CellphoneNumberConsent&quot;: &quot;YES&quot;,
              &quot;Consent_Given&quot;: &quot;Y&quot;,
              &quot;DoB&quot;: &quot;1993-07-10T16:00:00.000Z&quot;,
              &quot;EmailaddressConsent&quot;: &quot;NotApplicable&quot;,
              &quot;First_Name&quot;: &quot;First_Name_5&quot;,
              &quot;Gender&quot;: &quot;M&quot;,
              &quot;Last_Name&quot;: &quot;Last_Name_5&quot;,
              &quot;Middle_Name&quot;: null,
              &quot;PrimaryLanguage&quot;: [
                  &quot;English&quot;
              ],
              &quot;SecondaryLanguage&quot;: [
                  &quot;Hindi&quot;
              ],
              &quot;addionalIdentificationType&quot;: &quot;NO&quot;,
              &quot;cellphoneNumber&quot;: &quot;1234567890&quot;,
              &quot;countryName&quot;: &quot;IND&quot;,
              &quot;householdResponsibility&quot;: &quot;child&quot;,
              &quot;poorCardHas&quot;: &quot;N&quot;,
              &quot;poorCardReason&quot;: &quot;OTH&quot;,
              &quot;postalCode&quot;: &quot;123456&quot;,
              &quot;profilePicture&quot;: null,
              &quot;provinceCity&quot;: &quot;Province_5&quot;
          },
          &quot;createdBy&quot;: &quot;MAM_5@123.com&quot;,
          &quot;dateCreated&quot;: &quot;2021-01-01T17:20:33.134Z&quot;,
          &quot;type&quot;: &quot;profile&quot;
      }
  }, {
      &quot;answersData&quot;: {
          &quot;employeeId&quot;: &quot;17k9i&quot;,
          &quot;answers&quot;: {
              &quot;Address_2&quot;: &quot;Address_Line_2_6&quot;,
              &quot;Address_2_CC&quot;: &quot;Address_2_CC_6&quot;,
              &quot;CellphoneNumberConsent&quot;: &quot;YES&quot;,
              &quot;Consent_Given&quot;: &quot;Y&quot;,
              &quot;DoB&quot;: &quot;1983-07-10T16:00:00.000Z&quot;,
              &quot;EmailaddressConsent&quot;: &quot;NotApplicable&quot;,
              &quot;First_Name&quot;: &quot;First_Name_6&quot;,
              &quot;Gender&quot;: &quot;M&quot;,
              &quot;Last_Name&quot;: &quot;Last_Name_6&quot;,
              &quot;Middle_Name&quot;: null,
              &quot;PrimaryLanguage&quot;: [
                  &quot;Spanish&quot;
              ],
              &quot;SecondaryLanguage&quot;: [
                  &quot;Tagalog&quot;
              ],
              &quot;addionalIdentificationType&quot;: &quot;NO&quot;,
              &quot;cellphoneNumber&quot;: &quot;1234567890&quot;,
              &quot;countryName&quot;: &quot;IND&quot;,
              &quot;householdResponsibility&quot;: &quot;husband&quot;,
              &quot;poorCardHas&quot;: &quot;N&quot;,
              &quot;poorCardReason&quot;: &quot;OTH&quot;,
              &quot;postalCode&quot;: &quot;123456&quot;,
              &quot;profilePicture&quot;: null,
              &quot;provinceCity&quot;: &quot;Province_6&quot;
          },
          &quot;createdBy&quot;: &quot;MAM_6@123.com&quot;,
          &quot;dateCreated&quot;: &quot;2021-01-16T17:20:33.134Z&quot;,
          &quot;type&quot;: &quot;profile&quot;
      }
  }, {
      &quot;answersData&quot;: {
          &quot;employeeId&quot;: &quot;87p&quot;,
          &quot;answers&quot;: {
              &quot;Address_2&quot;: &quot;TEST123&quot;,
              &quot;Address_2_CC&quot;: &quot;Test&quot;,
              &quot;CellphoneNumberConsent&quot;: &quot;YES&quot;,
              &quot;Consent_Given&quot;: &quot;Y&quot;,
              &quot;DoB&quot;: &quot;1801-07-10T16:00:00.000Z&quot;,
              &quot;EmailaddressConsent&quot;: &quot;NotApplicable&quot;,
              &quot;First_Name&quot;: &quot;Test123&quot;,
              &quot;Gender&quot;: &quot;M&quot;,
              &quot;Last_Name&quot;: &quot;Test123&quot;,
              &quot;Middle_Name&quot;: null,
              &quot;PrimaryLanguage&quot;: [
                  &quot;English&quot;
              ],
              &quot;SecondaryLanguage&quot;: [
                  &quot;Kannada&quot;
              ],
              &quot;addionalIdentificationType&quot;: &quot;NO&quot;,
              &quot;cellphoneNumber&quot;: &quot;1234567890&quot;,
              &quot;countryName&quot;: &quot;IND&quot;,
              &quot;householdResponsibility&quot;: &quot;wife&quot;,
              &quot;poorCardHas&quot;: &quot;N&quot;,
              &quot;poorCardReason&quot;: &quot;OTH&quot;,
              &quot;postalCode&quot;: &quot;654321&quot;,
              &quot;profilePicture&quot;: null,
              &quot;provinceCity&quot;: &quot;Province_2&quot;
          },
          &quot;createdBy&quot;: &quot;jo@test.com&quot;,
          &quot;dateCreated&quot;: &quot;2021-02-23T17:20:33.134Z&quot;,
          &quot;type&quot;: &quot;profile&quot;
      }
  }, {
      &quot;answersData&quot;: {
          &quot;employeeId&quot;: &quot;09l07ytw&quot;,
          &quot;answers&quot;: {
              &quot;Address_2&quot;: &quot;TEST123&quot;,
              &quot;Address_2_CC&quot;: &quot;Test&quot;,
              &quot;CellphoneNumberConsent&quot;: &quot;YES&quot;,
              &quot;Consent_Given&quot;: &quot;Y&quot;,
              &quot;DoB&quot;: &quot;1801-07-10T16:00:00.000Z&quot;,
              &quot;EmailaddressConsent&quot;: &quot;NotApplicable&quot;,
              &quot;First_Name&quot;: &quot;Test123&quot;,
              &quot;Gender&quot;: &quot;M&quot;,
              &quot;Last_Name&quot;: &quot;Test123&quot;,
              &quot;Middle_Name&quot;: null,
              &quot;PrimaryLanguage&quot;: [
                  &quot;English&quot;
              ],
              &quot;SecondaryLanguage&quot;: [
                  &quot;Kannada&quot;
              ],
              &quot;addionalIdentificationType&quot;: &quot;NO&quot;,
              &quot;cellphoneNumber&quot;: &quot;1234567890&quot;,
              &quot;countryName&quot;: &quot;IND&quot;,
              &quot;householdResponsibility&quot;: &quot;wife&quot;,
              &quot;poorCardHas&quot;: &quot;N&quot;,
              &quot;poorCardReason&quot;: &quot;OTH&quot;,
              &quot;postalCode&quot;: &quot;654321&quot;,
              &quot;profilePicture&quot;: null,
              &quot;provinceCity&quot;: &quot;Province_2&quot;
          },
          &quot;createdBy&quot;: &quot;jo@test.com&quot;,
          &quot;dateCreated&quot;: &quot;2021-02-23T17:20:33.134Z&quot;,
          &quot;type&quot;: &quot;profile&quot;
      }
  }
  </code></pre>
  <p>]</p>
  <p>When I try to read the <code>json</code> file using pandas, I get the below error</p>
  <blockquote>
  <p>ValueError: Expected object or value</p>
  </blockquote>
  <p>I already tried the below approaches</p>
  <pre><code>df = pd.read_json(open(r&quot;test_data.json&quot;, &quot;r&quot;,encoding=&quot;utf8&quot;))
  df = pd.read_json(r'test_data.json', encoding='utf-8-sig')
  basepath = 'C:\\Users\\test\\Downloads' 
  pd.read_json(basePath + '\\test_data.json') 
  </code></pre>
  <p>I expect my output to be like as shown below</p>
  <p><a href="https://i.stack.imgur.com/NRBUJ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/NRBUJ.png" alt="enter image description here" /></a></p>