Click here to Skip to main content
15,891,597 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

I have a Ms Access database. In this inside one of the table, I have a column (which is of 'memo' type) which contain high number of characters for g. 2000 to 4000 characters.

Using Ado.net, I tried to load the values present in a particular row in the datatable for further computation.

I am simply writing a sql query using ADO.net to collect a table based on certain parameters into a DataTable.

And when I am checking the text contained in cell of that particular column, it is truncated to 256 characters only. This is the issue where I need your help.

BTW below is the code :

----------------------

C#
string strsql = "Select distinct c_ImageName,c_tttText,c_Page from ttt_RawData where c_ImageName = '"+filepath[t].ToString()+"' and c_Page ='"+myPagesarray[i]+"'";
 
DataUtility objDUT = new DataUtility();//Class to access ADO methods
 
DataTable dteachfieldperpagetttvalue = objDUT.GetDataTable(strsql);
 
string datafetchedfromdatabase = "";
if (dteachfieldperpagetttvalue.Rows.Count > 0)
{
datafetchedfromdatabase = dteachfieldperpagetttvalue.Rows[0]["c_tttText"].ToString();
}


---------------

Thanks in advance.

Ankit
Posted
Updated 26-Apr-13 14:56pm
v2
Comments
[no name] 26-Apr-13 21:01pm    
Have you checked the MaxLength property for your datatable columns?
TnTinMn 27-Apr-13 21:03pm    
If you expect any meaningful responses, you are going to have to show your DataUtility class. In particular, the GetDataTable method.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900