ParamQuery grid support forum
General Category => ParamQuery Pro Evaluation Support => Topic started by: stevejacobsen on May 27, 2016, 04:24:16 am
-
I captured the post values and got this:
pq_filter:{"mode":"AND","data":[{"dataIndx":"Description","value":"mo","condition":"begin","dataType":"string","cbFn":""}]}
I then use this code to separate it:
$filterQuery = "";
$filterParam = array();
if (isset($_GET["pq_filter"])) {
$pq_filter = $_GET["pq_filter"];
$dsf = FilterHelper::deSerializeFilter($pq_filter);
$filterQuery = $dsf->query;
$filterParam = $dsf->param;
}
and I see the value when I echo $filterQuery
where Description like CONCAT( ?, '%')
-
This is expected and is ok.
It's a parameterized query, actual values are substituted by $filterParam
-
I resoled, changed source :
//$stmt = $dbh->query( $sql );
$stmt = $dbh->prepare($sql);