[Mono-dev] Strange MSSQL provider behavior

Andrew Koryavchenko avk at rsdn.ru
Fri Mar 21 13:21:22 EDT 2008


In the code sample verbatim string is used and doubling slash isn't required.

On 3/21/08, Nagappan A <nagappan at gmail.com> wrote:
> Hello,
>
> My guess is connection string is incorrect, it has to be "127.0.0.1\\DEV"
> instead of "127.0.0.1\DEV". Could you try with this ?
>
> Thanks
> Nagappan
>
>
> On Fri, Mar 21, 2008 at 7:43 AM, Andrew Koryavchenko <avk at rsdn.ru> wrote:
>
> >
> > Test sample:
> >
> > static void Main()
> > {
> >        const string connStr =
> >                        @"User
> ID=Tornado;Pwd=parusina;Net=dbmssocn;Server=127.0.0.1\DEV;Integrated
> >
> > Security=no;Initial Catalog=LocalDB";
> >        const string cmdText = "SELECT COUNT(*) FROM units";
> >        for (var i = 0; i < 3; i++)
> >
> >                using (var con = new SqlConnection(connStr))
> >                using (var cmd = new SqlCommand(cmdText, con))
> >                {
> >                        con.Open();
> >                        Console.WriteLine("{0} : {1}", i,
> cmd.ExecuteScalar());
> >                }
> > }
> >
> > https://bugzilla.novell.com/show_bug.cgi?id=372932
> >
> >
> >
> >
> >
> > --
> > With best regards,
> >  Andrew Koryavchenko, Visual C# MVP [Architecture].
> > _______________________________________________
> > Mono-devel-list mailing list
> > Mono-devel-list at lists.ximian.com
> >
> http://lists.ximian.com/mailman/listinfo/mono-devel-list
> >
>
>
>
> --
> Linux Desktop (GUI Application) Testing Project -
> http://ldtp.freedesktop.org
> http://nagappanal.blogspot.com


-- 
With best regards,
  Andrew Koryavchenko, Visual C# MVP [Architecture].


More information about the Mono-devel-list mailing list