37 columns in a datatable
37 columns in a datatable
Hello,
We've a datatable (version 1.7.5) using AJAX as the data source in ASP.NET. The data table consists of 37 columns and is displayed completely in the development environment. However, when it is moved to the testing environment (IIS 7), no data gets displayed in the table. If the total no. of columns are brought down to 28, the data starts displaying properly.
We also tried setting JSONMAxDataLength in web.config but doesn't work.
Is there any restriction on the size or no. of columns?
I've been stuck up with the problem since the last 2 weeks. Kindly let me know any workable solution.
Many Thanks,
Denil
We've a datatable (version 1.7.5) using AJAX as the data source in ASP.NET. The data table consists of 37 columns and is displayed completely in the development environment. However, when it is moved to the testing environment (IIS 7), no data gets displayed in the table. If the total no. of columns are brought down to 28, the data starts displaying properly.
We also tried setting JSONMAxDataLength in web.config but doesn't work.
Is there any restriction on the size or no. of columns?
I've been stuck up with the problem since the last 2 weeks. Kindly let me know any workable solution.
Many Thanks,
Denil
This discussion has been closed.
Replies
No there isn't. If you are using server-side processing and GET then your server might be limiting the GET URL size. However, without a test case, I can't say if this is the case. Please link to a test case as noted in the forum rules.
Allan
The JSON is getting generated properly on the server side. Also, we're trying to make visible just a single record.
However, there is no record behind shown in the datatable. Very strange behavior.
The JSON generated from the server side is:
{"sEcho":2,"iTotalRecords": 1180,"iTotalDisplayRecords": 1,"aaData": [[9,"View","","","21-Jun-2012","A00044444","Tampered Age Proof" ,"Replacement","","AB1635" ,"Kailash Prasad" ,"dfg" ,"dfg" ,"Patna 2","29" ,"Central","DSF","" ,"" ,"17-Jan-2013","","","","","","Accepted","","",""]]}
And the rendering in the page is:
var oTable = $('#appList')
.dataTable(
{
"oLanguage": {
"sSearch": "Search all columns:"
},
"bProcessing": true,
"bServerSide": true,
"sAjaxSource": "../UnderwritingDataTablesJSON.aspx?Type=Compliance&FromDate="
+FromDate+"&ToDate="+ToDate,
"bAutoWidth": false,
"aoColumns": [{
"sWidth": "3%"
}, {
"sWidth": "8%",
"bSortable" : false
}, {
"sWidth": "8%",
"bSortable" : false
}, {
"sWidth": "8%",
"bSortable" : false
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}, {
"sWidth": "9%"
}
],
"sPaginationType": "full_numbers"
});
$("#appList thead input").keyup(
function() {
/* Filter on the column (the index) of this element */
oTable.fnFilter(this.value, $(
"#appList thead input").index(this));
});
$("#appList thead input").each(function(i) {
asInitVals[i] = this.value;
});
$("#appList thead input").focus(function() {
if (this.className == "search_init") {
this.className = "";
this.value = "";
}
});
$("#appList thead input").blur(
function(i) {
if (this.value == "") {
this.className = "search_init";
this.value = asInitVals[$(
"#appList thead input").index(this)];
}
});
Allan
http://www.datatables.net/forums/discussion/5960/how-many-columns-can-i-add-from-datatable-by-aocolumns/p1
we tried "sServerMethod": "POST" as well. BUt no success so far.
in web.config.
Thanks for all the assistance.
The problem we're facing is that the data table is not visible in IE7. It works perfectly in IE 8 and above. Kindly let me know if there is any fix for the same.
Regards,
Denil
Allan
We upgraded from Datatables 1.7.5 to 1.9 and now we're able to see the records.
The problem we're facing now is inside the thead declaration, we have the column headers as well as the filter textboxes, which cause the formatting distortion due to css being applied to the cells containing search textboxes. It works fine when we move the filter textboxes to tfoot but we don't want the search in tfoot.
The sample html generated is as below:
Id
View
Edit
Delete
Case initiated by
I hope this gives you a fair idea of what the problem is.
Many Thanks,
Denil