Closed karthikmallireddy closed 2 years ago
Can you describe what issues do you have with reading Parquet files?
I'm getting the attached error while reading the parquet file.
Controller File:
using DuckDB.NET.Data; using DuckDB_Demo1.Models; using Microsoft.AspNetCore.Mvc; using Newtonsoft.Json; using System.Diagnostics; using System.Net; using System.Runtime.InteropServices; using System.Text;
namespace DuckDB_Demo1.Controllers
{
public class HomeController : Controller
{
private readonly ILogger
public HomeController(ILogger<HomeController> logger)
{
_logger = logger;
}
public string Index()
{
using (var duckDBConnection = new DuckDBConnection("Data Source=:memory:"))
{
duckDBConnection.Open();
var command = duckDBConnection.CreateCommand();
command.CommandText = "Select count(*) from parquet_scan('p3new.parquet') limit 100;";
var executeScalar = command.ExecuteScalar();
}
return "";
}
}
}
Does the same code work when you use native duckdb library?
Yes with the CLI I can able to execute the same query.
Which version of duckdb.dll do you have in your project?
V2.9.1
Try using 0.3.1
It works with 0.3.1 version. Thanks Giorgi
Am trying to read parquet from aws s3, but it seems not working. Could you please help if you have any samples around this that would be really helpful. Thanks
Glad that it works for you.
I'm not able to find 0.3.1 Version where do you find that DLL, Can you please share that link.
You can download it from https://github.com/duckdb/duckdb/releases/tag/v0.3.1
Is it possible for you to share a working copy with parquet here, It would be great help thanks in advance.
Download Windows build from the link above.
Getting a lot of errors while doing it, Is there a way can you please send the working project with Duck db 0.3.1 if possibly only.
@karthikmallireddy I used the same code (in a console) which you mentioned above, what errors you are facing?
How to read Parquet files directly using the Duckdb.net