vinayvenk commented on issue #41893:
URL: https://github.com/apache/arrow/issues/41893#issuecomment-2142175816

   
   GM @amoeba  it is pretty much standard code that i got from the example and 
I tried using 16.0.1, 16.0.0 and 15.0.1
   
   String uri = parquetFile.toURI().toString();
   ScanOptions options = new ScanOptions(/* batchSize */ 32768);
   try (BufferAllocator allocator = new RootAllocator();
                   DatasetFactory datasetFactory = new 
FileSystemDatasetFactory(allocator, NativeMemoryPool.getDefault(),
                           FileFormat.PARQUET, uri);                
                   Dataset dataset = datasetFactory.finish();                
                   Scanner scanner = dataset.newScan(options);                
                   ArrowReader reader = scanner.scanBatches()) {  
               int batchCount = 0;            
               while (reader.loadNextBatch()) {                
                   try (VectorSchemaRoot root = reader.getVectorSchemaRoot()) {
                          //function to create csv data
                           createCSV()
                  }
   it fails when it tries to load the second batch.  


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to