Added data does not match known number of columns
Added data does not match known number of columns
todd.bruner
Posts: 3Questions: 0Answers: 0
I'm receiving this error: Added data does not match known number of columns
and I can't find my problem. The table has 5 columns, and the aaData has 5 columns.
DataTables version (1.6)
Any help would be greatly appreciated...
The table is defined in HTML thusly:
[code]
Select
Subject
Owner
Opened
Status
[/code]
The Javascript for DataTables is:
[code]
$(document).ready(
function() {
$("#event_select_table").dataTable({
"bJQueryUI": true,
"sPaginationType": "full_numbers",
"bProcessing": true,
"bServerSide": true,
"sAjaxSource": "/scot/event?command=retrievejson"
});
}
);
[/code]
the Ajax call returns the following json:
[code]
{
"iTotalDisplayRecords" : "1",
"iTotalRecords" : "1",
"aaData" : [
"",
"Sluggo! ",
"tbruner",
"2010-04-07 14:56:21",
"open"
],
"sEcho" : "1"
}
[/code]
Todd
and I can't find my problem. The table has 5 columns, and the aaData has 5 columns.
DataTables version (1.6)
Any help would be greatly appreciated...
The table is defined in HTML thusly:
[code]
Select
Subject
Owner
Opened
Status
[/code]
The Javascript for DataTables is:
[code]
$(document).ready(
function() {
$("#event_select_table").dataTable({
"bJQueryUI": true,
"sPaginationType": "full_numbers",
"bProcessing": true,
"bServerSide": true,
"sAjaxSource": "/scot/event?command=retrievejson"
});
}
);
[/code]
the Ajax call returns the following json:
[code]
{
"iTotalDisplayRecords" : "1",
"iTotalRecords" : "1",
"aaData" : [
"",
"Sluggo! ",
"tbruner",
"2010-04-07 14:56:21",
"open"
],
"sEcho" : "1"
}
[/code]
Todd
This discussion has been closed.
Replies
the correct json looks like:
[code]
{
"iTotalDisplayRecords" : "1",
"iTotalRecords" : "1",
"aaData" : [
[
"",
"Sluggo! ",
"tbruner",
"2010-04-07 14:56:21",
"open"
]
],
"sEcho" : "1"
}
[/code]