I'm making tests on master-detail.php and I noticed that this command:
// and use in sql for filteration
$grid->select_command = "SELECT CALL_ID, CALL_CLIENT_CODE, CALL_DATE FROM CALLS WHERE CALL_CLIENT_CODE = 'C 44 4'";
is passed omitting all blank spaces but one. I found it simply ordering by a non existing field, so that the following error could be shown:
Couldn't execute query. SQLState: 42S22 Error Code: 207 Message: [Microsoft][ODBC Driver 11 for SQL Server][SQL Server]Invalid column name 'CALL_IDx'. – select top (20+0) CALL_ID, CALL_CLIENT_CODE, CALL_DATE FROM CALLS WHERE CALL_CLIENT_CODE = 'C 44 4' ORDER BY CALL_IDx DESC
As you can see the variable 'C 44 4' has been changed to 'C 44 4'.
It seems that posting this question had the same problem!
The variable 'C (10 spaces follows) 2' has been changed to 'C 2'
It looks like inside lib, following line is causing this:
$this->select_command = preg_replace("/[ ]+/"," ",$this->select_command);
You can edit jqgrid_dist.php and comment it out.
It does not do any thing special except making readability of sql query.