invalid datatype error

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for SQLite
Post Reply
commodoreKid
Posts: 3
Joined: Tue 23 Dec 2008 20:40

invalid datatype error

Post by commodoreKid » Tue 23 Dec 2008 21:01

I am evaluating dotConnector for SQLite for my company. I am particularly interested in using it with LINQ.

I have a simple database that I have created. I used EntityDeveloper to create a DataContext class for the database.

I have written some code to return information from a table in the database but I am getting an error when I try to execute the foreach loop. The error is reporting that the object q is an "Invalid datatype: Integer". Here is the code:

Code: Select all

testDataContext db = new 

var q =
     from x in db.AssetClass
     select x;
 
foreach (var ac in q)
      Console.WriteLine("ID = {0}, Name = {1}", ac.ID, ac.Name);
Can anyone please help me figure this out? If it would help to have my DataContext class or the database to help figure this out, please let me know. Thanks for the help.

AndreyR
Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Post by AndreyR » Thu 25 Dec 2008 11:04

Thank you for the report, we have reproduced the problem and now we are investigating it. As a workaround, try using the INT synonym instead of INTEGER in your DB creation script..

commodoreKid
Posts: 3
Joined: Tue 23 Dec 2008 20:40

Post by commodoreKid » Mon 29 Dec 2008 14:23

That worked. Thank you very much!

Post Reply