[Mono-bugs] [Bug 609109] [Regression] Incoming tablular data stream (TDS) remote procedure call (RPC) protocal stream is incorrect.

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Tue Jun 29 17:46:01 EDT 2010


http://bugzilla.novell.com/show_bug.cgi?id=609109

http://bugzilla.novell.com/show_bug.cgi?id=609109#c13


--- Comment #13 from scott fluto <srfcanada at hotmail.com> 2010-06-29 21:46:00 UTC ---
here is another test, notice parameter 2 is /0 (null character). if you remove
the null character then everything works ok. It looks like this character is
causing all the problems. Maybe for the binary data, there is one of these
characters in it that is causing the same problem . At any rate hopfully this
is enough test cases to fix this problem since we have over 50 tests that are
failing because of this and will go a long way in eliminating the failed tests.


using System;
using System.Data;
using System.Data.SqlClient;
using System.Collections.Generic;
using System.Runtime.Serialization.Formatters.Binary;
using System.IO;

   public class TestProject
   {



      static void Main(string[] args)
      {

    Console.WriteLine("Inserting");

IDbCommand command = new SqlCommand();
          command.Connection = new SqlConnection("Data
Source=129.2.10.133;Database=testscott;Integrated Security=False;Connection
timeout=200;User 

Id=sa;Password=cmg434");
          command.CommandType = CommandType.Text;
          command.CommandText = "INSERT INTO [EROOTTESTOBJECT] ([COMMITCOUNT],
[TESTDATE], [TESTSTRING], [TESTDOUBLE], [TESTINT], [TESTINT64], [SINGLECHILD],
[LABEL], 

[PERSISTABLEBACKREFERENCES], [PERSISTABLECASECONTEXTID],
[PERSISTABLECASECONTEXTREFERENC], [NAME], [BINARYTEST], [CHILDSHARED],
[CHILDNOLAZY], [SINGLEDOMAINOBJECT], 

[TESTBLOB], [INTERFACEOBJECT], [DOMAINLISTCOLLECTION1], [SHAREDLIST],
[SHAREDLIST2], [RELATIONSHIPLISTCOLLECTION1], [SINGLERELATIONSHIP1], 

[DOMAINDICTIONARYCOLLECTION1], [SHAREDDICTIONARY], [SHAREDDICTIONARY2],
[SHAREDSINGLERELATIONSHIP], [STRINGLIST], [STRINGVALIDATEDLIST],
[STRINGVALIDATEDDICTIONARY], 

[DICTIONARYKEY], [DICTIONARYKEYBINARY], [CHILDADICTIONARY], [CHILDACOLLECTION],
[ILISTCOLLECTION1], [ILISTCOLLECTION2], [DOMAINLISTCOLLECTION2], 

[DOMAINLISTCOLLECTION3], [DOMAINLISTCOLLECTION4], [VALIDATEDLISTCOLLECTION1],
[VALIDATEDLISTCOLLECTION2], [VALIDATEDLISTCOLLECTION3],
[VALIDATEDLISTCOLLECTION4], 

[DOMAINDICTIONARYCOLLECTION2], [DOMAINDICTIONARYCOLLECTION3],
[DOMAINDICTIONARYCOLLECTION4], [VALIDATEDDICTIONARYCOLLECTION1],
[VALIDATEDDICTIONARYCOLLECTION2], 

[VALIDATEDDICTIONARYCOLLECTION3], [VALIDATEDDICTIONARYCOLLECTION4],
[RELATIONSHIPLISTCOLLECTION2], [RELATIONSHIPLISTCOLLECTION3],
[SINGLERELATIONSHIP2], 

[SINGLERELATIONSHIP3], [ARRAY1], [COLLECTIONLIST], [ORIGINAL],
[ISBACKREFERENCETRACKINGENABLED], [CASECONTEXTBEHAVIOR], [DESCRIPTION],
[CREATED], [ID]) VALUES (@p0, 

@p1, @p2, @p3, @p4, @p5, @p6, @p7, @p8, @p9, @p10, @p11, @p12, @p13, @p14,
@p15, @p16, @p17, @p18, @p19, @p20, @p21, @p22, @p23, @p24, @p25, @p26, @p27,
@p28, @p29, 

@p30, @p31, @p32, @p33, @p34, @p35, @p36, @p37, @p38, @p39, @p40, @p41, @p42,
@p43, @p44, @p45, @p46, @p47, @p48, @p49, @p50, @p51, @p52, @p53, @p54, @p55,
@p56, @p57, 

@p58, @p59, @p60, @p61)";

          command.Connection.Open();

          IDbDataParameter dbParam= new SqlParameter();
          dbParam.ParameterName = "@p0";
          dbParam.DbType = DbType.Int32;
          dbParam.Value = 1;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p1";
          dbParam.DbType = DbType.DateTime;
          dbParam.Value = new DateTime(2010, 6, 29, 4, 42, 24);
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p2";
          dbParam.DbType = DbType.String;         
          dbParam.Value = "\0";
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p3";
          dbParam.DbType = DbType.Double;
          dbParam.Value = 0;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p4";
          dbParam.DbType = DbType.Int32;
          dbParam.Value = 0;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p5";
          dbParam.DbType = DbType.Int64;
          dbParam.Value = 0;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p6";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = DBNull.Value;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p7";
          dbParam.DbType = DbType.Guid;
          dbParam.Value = new Guid("f4c5bca3-f753-48f6-b363-9da40390744c");
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p8";
          dbParam.DbType = DbType.AnsiString;
          dbParam.Value = "";
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p9";
          dbParam.DbType = DbType.Guid;
          dbParam.Value = new Guid("00000000-0000-0000-0000-000000000000");
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p10";
          dbParam.DbType = DbType.Int32;
          dbParam.Value = 0;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p11";
          dbParam.DbType = DbType.String;
          dbParam.Value = "RootTestObject {jombaplgnefbhgfenihdnlbacdhcoikj}";
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p12";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = DBNull.Value;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p13";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = DBNull.Value;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p14";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = DBNull.Value;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p15";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = DBNull.Value;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p16";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = DBNull.Value;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p17";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = DBNull.Value;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p18";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[]{};
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p19";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p20";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p21";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p22";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p23";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p24";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p25";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p26";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = DBNull.Value;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p27";
          dbParam.DbType = DbType.Binary;

          IList<string> stringlist = new List<string>();
          BinaryFormatter binaryFormatter = new BinaryFormatter();
          MemoryStream ms1 = new MemoryStream();
          binaryFormatter.Serialize(ms1, stringlist);


          dbParam.Value = ms1.GetBuffer();
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p28";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[1000];
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p29";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p30";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p31";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p32";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p33";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p34";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p35";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p36";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p37";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p38";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p39";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p40";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p41";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p42";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = DBNull.Value;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p43";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p44";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p45";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p46";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);


          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p47";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);


          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p48";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);


          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p49";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);


          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p50";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);


          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p51";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);


          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p52";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = DBNull.Value;
          command.Parameters.Add(dbParam);


          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p53";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = DBNull.Value;
          command.Parameters.Add(dbParam);


          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p54";
          String[] m_array1 = new string[10];
          BinaryFormatter binaryFormatter2 = new BinaryFormatter();
          MemoryStream ms2 = new MemoryStream();
          binaryFormatter2.Serialize(ms2, m_array1);


      dbParam.Value = new Byte[] { };
          dbParam.DbType = DbType.Binary;
          command.Parameters.Add(dbParam);


          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p55";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = new Byte[] { };
          command.Parameters.Add(dbParam);


          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p56";
          dbParam.DbType = DbType.Binary;
          dbParam.Value = DBNull.Value;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p57";
          dbParam.DbType = DbType.Boolean;
          dbParam.Value = 1;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p58";
          dbParam.DbType = DbType.Byte;
          dbParam.Value = 0;
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p59";
          dbParam.DbType = DbType.String;
          dbParam.Value = "";
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p60";
          dbParam.DbType = DbType.DateTime;
          dbParam.Value = new DateTime(2010, 6, 29, 4, 42, 24);
          command.Parameters.Add(dbParam);

          dbParam = new SqlParameter();
          dbParam.ParameterName = "@p61";
          dbParam.DbType = DbType.Guid;
          dbParam.Value = Guid.NewGuid();
          command.Parameters.Add(dbParam);

          command.ExecuteNonQuery();


    Console.WriteLine("Finished Inserting");
      }

   }

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list