SWAMY YT

SWAMY YT

  • 1.1k
  • 643
  • 30.2k

Cannot create a row of size 12573 which is greater than the

Oct 16 2019 7:19 AM
 
DashboardContext context = new DashboardContext();
DataTable dataTable = new DataTable();
SqlDataAdapter sqlDataAdapter = new SqlDataAdapter();
sqlDataAdapter.SelectCommand = new SqlCommand();
sqlDataAdapter.SelectCommand.CommandTimeout = 120;
sqlDataAdapter.SelectCommand.CommandType = CommandType.StoredProcedure;
sqlDataAdapter.SelectCommand.CommandText = "STRPROCEDURE_Name";
 
sqlDataAdapter.SelectCommand.Connection = new SqlConnection(context.Database.Connection.ConnectionString);
sqlDataAdapter.SelectCommand.Parameters.Add("@StorePK", SqlDbType.UniqueIdentifier).Value = (object)storePk;
sqlDataAdapter.Fill(dataTable);
 
while calling that  sqlDataAdapter.Fill(dataTable) function i am getting an exception "Cannot create a row of size 12573 which is greater than the allowable maximum row size of 8060."   
 
can anyone please help me out by a resolution and how cn i limit the resultant row size to the its maximum size.
 
any help woukd be appreciated 
 

Answers (1)