Error: Table 'mydb.ajax' doesn't exist

Error: Table 'mydb.ajax' doesn't exist

rksrks Posts: 5Questions: 0Answers: 0
edited March 2014 in DataTables 1.9
[DataTables Server Side PHP][1]

When I try to use the default DataTables server side script I get Table 'mydb.ajax' doesn't exist. Needless to say, no data is being returned from the db.

The code I've actually edited in that file is:

[code]/* Array of database columns which should be read and sent back to DataTables. Use a space where
* you want to insert a non-database field (for example a counter or static image)
*/
$aColumns = array('person', 'object', 'location');
/* Indexed column (used for fast and accurate table cardinality) */
$sIndexColumn = "Key";
/* DB table to use */
$sTable = "ajax";
/* Database connection information */
$gaSql['user'] = "myuser";
$gaSql['password'] = "mypass";
$gaSql['db'] = "mydb";
$gaSql['server'] = "mysite.com";
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* If you just want to use the basic configuration for DataTables with PHP server-side, there is
* no need to edit below this line
*/[/code]

Yes...I've changed the vars to the real values for user, pass, db, and server. I'm calling this file via jquery like:

[code]$(".easy-table").dataTable(
"bProcessing": true,
"bServerSide": true,
"sAjaxSource": "phpprocess.php"
);[/code]

I'm using just what I see in that one example so maybe it's not all inclusive and I'm still missing something.

[1]: http://datatables.net/examples/data_sources/server_side.html

Replies

  • allanallan Posts: 63,494Questions: 1Answers: 10,470 Site admin
    I'm afraid that without access to the server, there is very little we can do to debug this, since as you can see from my example pages the script does work. All I can suggest you do is debug the connection.

    Allan
This discussion has been closed.