[Mono-bugs] [Bug 76961][Wis] New - r54161 caused regression in Npgsql SingleRow support

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Sat Dec 10 09:37:46 EST 2005


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by nazgul at omega.pl.

http://bugzilla.ximian.com/show_bug.cgi?id=76961

--- shadow/76961	2005-12-10 09:37:46.000000000 -0500
+++ shadow/76961.tmp.7071	2005-12-10 09:37:46.000000000 -0500
@@ -0,0 +1,69 @@
+Bug#: 76961
+Product: Mono: Class Libraries
+Version: 1.0
+OS: 
+OS Details: mono svn
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Wishlist
+Component: Sys.Data
+AssignedTo: tsenganal at novell.com                            
+ReportedBy: nazgul at omega.pl               
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL: 
+Summary: r54161 caused regression in Npgsql SingleRow support
+
+Please fill in this template when reporting a bug, unless you know what you
+are doing.
+Description of Problem:
+After the patch from r54161 SingleRow flag in ExecuteReader causes syntax
+error in underlying sql query
+
+Steps to reproduce the problem:
+1. Bring postgres sql db up.
+2. Compile following program with monosvn/mcs t.cs -r:Npgsql.dll -r:System.Data
+
+using Npgsql;
+using System.Data;
+
+class M {
+  static void Main () {
+       string connectionString =
+          "Server=localhost;" +
+          "Database=test;" +
+          "User ID=postgres;" +
+          "Password=sql;";
+
+       NpgsqlConnection dbcon = new NpgsqlConnection (connectionString);
+       dbcon.Open ();
+
+       string query =  "SELECT * FROM employee WHERE firstname = 'Kamil'";
+
+       NpgsqlCommand mycmd = new NpgsqlCommand (query, dbcon);
+
+       mycmd.ExecuteReader(CommandBehavior.SchemaOnly |
+CommandBehavior.SingleRow);
+  }
+}
+
+3. Execute t.exe
+
+Actual Results:
+syntax error at or near "limit"
+Severity: ERROR
+Code: 42601
+in <0x00054> Npgsql.NpgsqlConnector:CheckErrors ()
+in <0x0001c> Npgsql.NpgsqlConnector:CheckErrorsAndNotifications ()
+in <0x0005f> Npgsql.NpgsqlCommand:ExecuteCommand ()
+in <0x0003e> Npgsql.NpgsqlCommand:ExecuteReader (CommandBehavior cb)
+in (wrapper remoting-invoke-with-check) Npgsql.NpgsqlCommand:ExecuteReader
+(System.Data.CommandBehavior)
+in <0x00072> M:Main ()
+
+Expected Results:
+Clear run
+
+How often does this happen? 
+Always


More information about the mono-bugs mailing list