Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report for Bug 4289 on
GitHub or Developer Community if you have new
information to add and do not yet see a matching new report.
If the latest results still closely match this report, you can use the
In special cases on GitHub you might also want the comments:
GitHub Markdown with public comments
This function fails with System.OverflowException : Value was either too large or too small for an Int32.
public void StartMaxTest()
var conn = new SqliteConnection("Data Source="+System.IO.Path.GetTempFileName());
var cmd = conn.CreateCommand();
cmd.CommandText = "CREATE TABLE [Test] ([UInt32] BIGINT NOT NULL);";
cmd.CommandText = "INSERT INTO [Test] VALUES (?);";
var p = cmd.CreateParameter();
p.Value = UInt32.MaxValue;
If I change one line to:
p.Value = (long) UInt32.MaxValue;
it works correctly. It seems to be mapping a UInt32 to a Int32 instead of Int64.
This functionality works correctly on the Community.CsharpSqlite version. (Even though you don't maintain this one, I thought I'd let you guys know anyway.)
Stack Trace of exception:
System.OverflowException : Value was either too large or too small for an Int32.
at System.Convert.ToInt32(UInt32 value)
at System.UInt32.System.IConvertible.ToInt32(IFormatProvider provider)
at System.Convert.ToInt32(Object value, IFormatProvider provider)
at Mono.Data.Sqlite.SqliteStatement.BindParameter(Int32 index, SqliteParameter param)
at Mono.Data.Sqlite.SqliteCommand.GetStatement(Int32 index)
at Mono.Data.Sqlite.SqliteDataReader..ctor(SqliteCommand cmd, CommandBehavior behave)
at Mono.Data.Sqlite.SqliteCommand.ExecuteReader(CommandBehavior behavior)
at Mono.Data.Sqlite.Orm.Tests.ColumnTypesTest.StartMaxTest() in ColumnTypesTest.cs: line 62
A pull on github: https://github.com/mono/mono/pull/438
closed on github 10/10/2012
When will this be pulled into the monotouch/monodroid builds?