Add option to specify busy timeout in underlying sqlite structure
[mono.git] / mcs / class / Mono.Data.SqliteClient / Mono.Data.SqliteClient / ChangeLog
1 2006-03-14  Kamil Skalski  <nazgul@nemerle.org>
2
3         * SqliteConnection.cs, Sqlite.cs: Add option for specifying busy
4         timeout in underlying sqlite structure. It allows enabling
5         automatic waiting for lock cleanup in multithreaded usage.
6         
7
8 2006-03-11  Joshua Tauberer  <tauberer@for.net>
9
10         * Use HGlobal rather than CoTaskMem String-To-Ptr functions in
11           Marshal class.  StringToCoTaskMemAnsi is broken (pending it
12           being fixed): it actually uses Ansi, instead of UTF-8.  Now,
13           Sqlite2 with no encoding parameter uses UTF-8 encoding.  Any
14           Sqlite2 DB since Jan. 20 was encoded in ANSI but unreadable
15           back.
16
17 2006-03-07  Kamil Skalski  <nazgul@nemerle.org>
18
19         * SqliteDataReader.cs: Handle null values in result as having
20         string type
21
22 2006-02-10  Joshua Tauberer  <tauberer@for.net>
23
24         * SqliteDataReader: Made 64bit clean.  Patch from
25           Joe Shaw <joeshaw@novell.com>.
26
27 2006-01-22  Joshua Tauberer  <tauberer@for.net>
28
29         Most of the below fixes (in previous changes too) are thanks
30         to Thomas Zoechling and Tom Surace, and the byte[]->blob
31         parameter binding is thanks to <pablosantosluac@terra.es>.
32         
33         * SqliteCommand.cs:
34           - Don't use a regex for finding parameters in v2.
35           It didn't work when there were no parameters in
36           the query (infinite loop of some sort -- should be filed
37           as a Mono bug I guess).  Just scan for parameters names
38           that aren't within quotes.
39           - That wasn't even being called.  Now it is.
40           - Marshaling for sqlite3_bind_parameter_name was wrong, as
41           was the unicode call to bind_text16 which was looking for
42           byte length of string while we were providing char length.
43           - Bind byte[] parameters as blobs.
44           - Trim the SQL string.  Trailing spaces makes it think
45           another statement is coming along.
46         * SqliteDataReader.cs: When DATE/DATETIME columns come
47           back as Int64s, return them using DateTime.FromFileTime.
48           And don't return Int64s as ints if they aren't in the
49           range of an int.
50           - Check column names case-insensitively (bug 77272).
51         * SqliteParameter.cs: Public parameter names made nicer.
52         * SqliteParameterCollection.cs: Allow users to set parameter
53           names with or without the : prefix that Sqlite wants.
54         * Sqlite.cs: Supporting changes.
55         * SqliteDataReader, SqliteConnection: ToLower with the
56           invariant culture (bug 77372).
57
58 2006-01-20  Joshua Tauberer  <tauberer@for.net>
59
60         * Sqlite3 calls now use unicode encoding.  Sqlite2
61           calls use ANSI encoding (a superset of the default
62           expected encoding ISO8859-1), unless the new
63           encoding= connection string argument is used,
64           in which case that encoding is used.  But that encoding
65           must use a single-byte null terminator, so only
66           UTF-8 is recommended.  This removes the dependency
67           on Mono.Posix.  If UTF-8 encoding is used, Sqlite2's
68           LIKE, GLOB, LENGTH, and SUBSTR aren't going to respect
69           multibyte chars unless Sqlite was specifically compiled
70           to do so.
71         * SqliteDataReader.this[] is fixed to wrap GetValue.
72
73 2006-01-06  Joshua Tauberer  <tauberer@for.net>
74
75         * SqliteDataReader.cs: GetFieldType can be called
76           before the reader is positioned on a row.  In that
77           case, return the types for the first row.
78
79 2006-01-02  Joshua Tauberer  <tauberer@for.net>
80
81         * SqliteCommand.cs: It was revealed that preparing
82           statements ahead of time was not possible as table
83           schema changes lead to errors.  This needed serious
84           reorganization.  SQL syntax errors and BUSY errors
85           are now raised in nice exceptions.
86         * SqliteDataReader.cs:
87                 * Use object[] in place of ArrayList for each row.
88                 * For Sqlite3, which remembers whether a value was
89                   an integer, text, real, or blob, actually return
90                   longs, strings, doubles, and byte[]s.
91                 * GetDataTypeName() works where possible (Sqlite3).
92                 * INT/INTEGER columns are now returned as ints,
93                   rather than longs, for Sqlite3.  Similarly for
94                   DATE and DATETIME columns, now returning DateTimes.
95         * SqliteConnection.cs.cs: BeginTransaction(IsolationLevel)
96           throws InvalidOperationException per the MS docs.
97         * SqliteExceptions.cs: New file with SqliteSyntaxException,
98           SqliteExecutionException, and its subclass SqliteBusyException.
99
100 2005-12-27  Jonathan Pryor  <jonpryor@vt.edu>
101
102         * SqliteCommand.cs: Use non-obsolete UnixMarshal members.
103
104 2005-10-06  Chris Lahey  <clahey@localhost.localdomain>
105
106         * SqliteCommand.cs (Prepare): Use UnixMarshal here to get proper
107         utf8 behavior.
108
109 2005-07-28  Joshua Tauberer <tauberer@for.net>
110
111         * Sqlite.cs, SqliteCommand.cs: Report string error messages
112         in prepare, for version 3.
113
114 2005-07-26  Joshua Tauberer <tauberer@for.net>
115
116         SQL commands can have multiple statements within them (i.e.
117         separated by semicolons).  Sqlite has to be instructed to
118         process each command.
119         
120         * Sqlite.cs: Pass the sql command as an IntPtr so we can
121           see where pzTail takes us.
122         * SqliteCommand.cs: Lazily load sql_params for good measure.
123           Iterate compile/prepare until each statement in the string
124           has been processed, and retain pointers to each compiled
125           statement.  When executing, run all of the statements.
126
127 2005-06-14  Thomas Zoechling <thomas.zoechling@gmx.at>
128
129         * Sqlite.cs:
130         - Added sqlite3_bind_* for native Sqlite3 Parameters
131         * SqliteCommand.cs
132         - Added methods for parameter processing/binding (sqlite3 uses bind / sqlite2 uses regEx to extract parameters)
133         - Sqlite uses ':' as delimeter!
134         * SqliteParameterCollection.cs
135         - Chris Turchin fixed a problem in the Parameter Hashmap
136         * SqliteTransaction.cs
137         - The CommandText for the Rollback Command was "COMMIT" ! ->changed :)
138
139 2005-05-20  Sureshkumar T  <tsureshkumar@novell.com>
140
141         * SqliteConnection.cs:
142         - SetConnectionString: trim white spaces, ignore empty connection
143         string options.
144         - SetConnectionString: if file://,db_file starts from pos 7 not 6.
145
146