|
caldewallace
|
 |
« on: October 13, 2011, 08:35:28 AM » |
|
I need help ...
I am making a query to link two tables with the following statement:
if($json->{'action'} == 'load'){ $sql = "SELECT servicios.nombre, agencias.nombre FROM servicios, agencias where agencias.id_agencia = servicios.id_agencia"; $handle = mysql_query($sql);
Should work, right? I tried the query in Phpadmin and correct ... I need to show the name of the agency and the service name. Appears correct, but when you load the grid can not see anything .... I tried also with INNER JOIN and does not work.
It would be wrong to teach the correct fields?
var dsOption= {
fields :[ {name : 'servicios.nombre' }, {name : 'agencias.nombre' } ], recordType : 'object' } var colsOption = [ {id: 'servicios.nombre' , header: "Nombre Servicio" , width :300, editor:{type:'text'} }, {id: 'agencias.nombre' , header: "Nombre Agencia" , width :300 , editor:{type:'text'}} ];
It is quite urgent because it is for a project ... thank you very much!
|