Cant get working connector with interbase

Hi there…We had tested your products(licenced dhtmxgrid) with mysql database with awesome results. we are migrating to an interbase db system. We are trying to connect without results.

Here´s the code…

<?php require("../../dhtmlx/dhtmlxConnector/codebase2/grid_connector.php"); require("../../dhtmlx/dhtmlxConnector/codebase2/db_pdo.php"); $res = new PDO("firebird:dbname=localhost:C:\\DB\\DB-MARBE.GDB", "SYSDBA", "masterkey"); $grid = new GridConnector($res,"PDO"); $grid->enable_log("log"); $grid->render_sql("SELECT CLIENTES.CODIGOCLIENTE AS NRO,CLIENTES.RAZONSOCIAL AS CLIENTE FROM CLIENTES","","CLIENTES.CODIGOCLIENTE(NRO),CLIENTES.RAZONSOCIAL(CLIENTE)"); ?>

AND RECEIVING THE FOLLOWING

Fatal error: Uncaught exception ‘PDOException’ with message ‘could not find driver’ in D:\AppServ\www\admin\php\ventas\clientes.php:7 Stack trace: #0 D:\AppServ\www\admin\php\ventas\clientes.php(7): PDO->__construct(‘firebird:dbname…’, ‘SYSDBA’, ‘masterkey’) #1 {main} thrown in D:\AppServ\www\admin\php\ventas\clientes.php on line 7

WHAT ARE WE DOING WRONG?

THANKS IN ADVANCE…

LUCAS

P.D.: IN CASE IT WORKS, WE ARE PLANNING BUYING PRO EDITION OF DHTMLX SUITE

Error seems to be not related to connector code - please check that you have related extension for PDO enabled in php.ini

Hi Stanislav. You were right. It solved the problem.
But is there a problem with the connector. It does not carry any date and does not execute the proper query.

Here´s the connector code

<?php require_once('../../auth.php'); ?> <?php require("../../dhtmlx/dhtmlxConnector/codebase2/grid_connector.php"); require("../../dhtmlx/dhtmlxConnector/codebase2/db_pdo.php"); $res = new PDO("firebird:dbname=localhost:C:\\DB\\DB-MARBE.GDB", "SYSDBA", "masterkey"); $grid = new GridConnector($res,"PDO"); $grid->set_encoding("iso-8859-1"); $grid->enable_log("log"); $grid->render_sql("SELECT CABEZACOMPROBANTES.RAZONSOCIAL AS ORGANIZACION,ROUND (CABEZACOMPROBANTES.NUMEROCOMPROBANTE,0) AS COMPROBANTE,ROUND (CABEZACOMPROBANTES.TOTAL,2) AS TOTAL,CABEZACOMPROBANTES.FECHACOMPROBANTE AS FECHA FROM CABEZACOMPROBANTES WHERE CABEZACOMPROBANTES.ANULADA = 0 AND CABEZACOMPROBANTES.CODIGOUSUARIO= '". $_SESSION['SESS_LOGIN'] ."'","CABEZACOMPROBANTES.NUMEROCOMPROBANTE(COMPROBANTE)","CABEZACOMPROBANTES.RAZONSOCIAL(ORGANIZACION),CABEZACOMPROBANTES.NUMEROCOMPROBANTE(COMPROBANTE),CABEZACOMPROBANTES.TOTAL(TOTAL),CABEZACOMPROBANTES.FECHACOMPROBANTE(FECHA)"); ?>

The resulting xml is:

But the query over the database brings correct results…(see attached file)

And the log file shows the following:

====================================
Log started, 27/04/2012 10:04:30

SELECT CABEZACOMPROBANTES.RAZONSOCIAL AS ORGANIZACION,ROUND (CABEZACOMPROBANTES.NUMEROCOMPROBANTE,0) AS COMPROBANTE,ROUND (CABEZACOMPROBANTES.TOTAL,2) AS TOTAL,CABEZACOMPROBANTES.FECHACOMPROBANTE AS FECHA FROM CABEZACOMPROBANTES WHERE CABEZACOMPROBANTES.ANULADA = 0 AND CABEZACOMPROBANTES.CODIGOUSUARIO= ‘JBORGONOVO’

Done in 0.0570299625397s

What´s wrong?

Thanks in advance.

Lucas


The SQL query in log file is the correct one, right?
This is code which connector will execute for data fetching, after that code will process and output all rows, it just has not default logic to filter-out results, so maybe there is still a problem with php-pdo-firebird driver