-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error parsing column 0 (Id=012eb03d-fa6c-4b00-a767-c3fef46a0325 - String) - SqlLite #1985
Comments
I thought guid parsed - I'll check when I get a second. What runtime/framework is this, out of curiosity? |
I use ASP Net Core 7 / EF Core 7 Thanks for your time. |
I get the same error but using DateTime in my class and using Postgree to do the query. Th error is parsing my column that is a DateTime and when particularly i do a pagination in the query to bring 100 registers. From 10 to 50 at least it works fine, but then when I search for 100 register it breaks whit this same error. |
This guid problem is still present on last version 2.1.44 no matter the database provider. By the way, is it possible that QueryAsync() method does not have "buffered" parameter? Is this an issue? |
It is not possible to unify the async buffered/unbuffered API efficiently; see: |
Ok, thank you! |
Dear,
I'm getting this error when using Dapper to retrieve data from a table that is in SqlLite, in SqlMapper.cs, line 3911
An unhandled exception occurred while processing the request.
AggregateException: One or more errors occurred. (Error parsing column 0 (Id=012eb03d-fa6c-4b00-a767-c3fef46a0325 - String))
System.Threading.Tasks.Task.ThrowIfExceptional(bool includeTaskCanceledExceptions)
DataException: Error parsing column 0 (Id=012eb03d-fa6c-4b00-a767-c3fef46a0325 - String)
Dapper.SqlMapper.ThrowDataException(Exception ex, int index, IDataReader reader, object value) in SqlMapper.cs, line 3911
Query
string q = "SELECT e.Id, e.Name, e.EmailAddress" +
" FROM EmailEmailList eel" +
" INNER JOIN Email e ON eel.EmailId = e.Id" +
" INNER JOIN EmailList el ON eel.EmailListId = el.Id" +
" WHERE el.Id = 1";
var x = _DBContext.Database.GetDbConnection().Query(q);
Class
public class Email
{
public Guid Id { get; set; } = Guid.NewGuid();
public String? Name { get; set; }
public string EmailAddress { get; set; } = null!;
public ICollection? EmailList { get; set; }
}
public class EmailEmailList
{
public Guid EmailId { get; set; }
public int EmailListId { get; set; }
}
public class EmailList
{
public int Id { get; set; }
public string Name { get; set; } = null!;
public string? Type { get; set; }
public virtual ICollection Email { get; set; } = null!;
}
The text was updated successfully, but these errors were encountered: