View Ticket
Not logged in
Ticket UUID: e36e05e2992afa41e41fc3b989be9281288294a0
Title: SqliteDataReader getOrdinal does not conform System.Data.Common.DbDataReader
Status: Closed Type: Code_Defect
Severity: Important Priority: Blocker
Subsystem: Data_Reader Resolution: Fixed
Last Modified: 2018-12-23 05:03:20
Version Found In:
User Comments:
anonymous added on 2018-12-21 10:29:22: (text/x-fossil-plain)

We encountered an issue with the method GetOrdinal on the SQLiteDataReader class. We expected an Exception when calling this method with a not existing column, but instead we got -1 as ordinal position.

According to the API description of System.Data.Common.DbDataReader this call should return an IndexOutOfRangeException instead of -1:

Can you please verify and confirm. And is it possible that this can be fixed?


Arjen van Efferen

mistachkin added on 2018-12-22 20:06:35: (text/x-fossil-plain)
I'm adding the "StrictConformance" connection flag in order to enable this
behavior.  In the future, this flag will be used to enable other features
needed for strict ADO.NET conformance.

mistachkin added on 2018-12-23 05:00:01: (text/x-fossil-plain)
Fixed on trunk via check-in [4012cc2587fb9149].

Using the new connection flag "StrictConformance" will enable throwing an
exception when the GetOrdinal method cannot find the column name.

mistachkin added on 2018-12-23 05:03:20: (text/x-fossil-plain)
It should be noted here that the new "StrictConformance" flag may be enhanced in
the future to enable other behaviors required for stricter ADO.NET conformance.