title: How to convert a JSON result to Parquet in python?
body: <p>Follow the script below to convert a JSON file to parquet format. I am using the pandas library to perform the conversion.
  However the following error is occurring: AttributeError: 'DataFrame' object has no attribute 'schema'
  I am still new to python.</p>
  
  <p>Here's the original json file I'm using:
  [
      {
          "a": "01",
          "b": "teste01"
      },
      {
          "a": "02",
          "b": "teste02"
      }
  ]</p>
  
  <p>What am i doing wrong?</p>
  
  <pre><code>import numpy as np
  import pandas as pd
  import pyarrow as pa
  import pyarrow.parquet as pq
  
  df = pd.read_json('C:/python/json_teste')
  
  pq = pa.parquet.write_table(df, 'C:/python/parquet_teste')
  </code></pre>
  
  <p>Error:</p>
  
  <pre><code>---------------------------------------------------------------------------
  AttributeError                            Traceback (most recent call last)
  &lt;ipython-input-23-1b4ced833098&gt; in &lt;module&gt;
  ----&gt; 1 pq = pa.parquet.write_table(df, 'C:/python/parquet_teste')
  
  C:\Anaconda\lib\site-packages\pyarrow\parquet.py in write_table(table, where, row_group_size, version, use_dictionary, compression, write_statistics, use_deprecated_int96_timestamps, coerce_timestamps, allow_truncated_timestamps, data_page_size, flavor, filesystem, **kwargs)
     1256     try:
     1257         with ParquetWriter(
  -&gt; 1258                 where, table.schema,
     1259                 filesystem=filesystem,
     1260                 version=version,
  
  C:\Anaconda\lib\site-packages\pandas\core\generic.py in __getattr__(self, name)
     5065             if self._info_axis._can_hold_identifiers_and_holds_name(name):
     5066                 return self[name]
  -&gt; 5067             return object.__getattribute__(self, name)
     5068 
     5069     def __setattr__(self, name, value):
  
  AttributeError: 'DataFrame' object has no attribute 'schema'
  </code></pre>
  
  <p>Print file:</p>
  
  <pre><code>#print 
  print(df)
     a        b
  0  1  teste01
  1  2  teste02
  
  #following columns
  df.columns
  Index(['a', 'b'], dtype='object')
  
  #following types
  df.dtypes
  a     int64
  b    object
  dtype: object
  </code></pre>