CONSULTA MYSQL / TDolphin
- Code: Select all Expand view
cSql := "SELECT cm.id_provee, pv.provee_nombres, cm.com_num_fac, "
cSql += "cm.com_fch_fac, cm.com_peso_kilo, cm.com_unidades "
cSql += "FROM ge_pollos_compras_master AS cm "
cSql += "LEFT JOIN ge_pollos_compras_detalles AS cd ON cm.id_provee = cd.id_provee "
cSql += "AND cm.com_num_fac = cd.com_num_fac "
cSql += "LEFT JOIN ge_provee_master AS pv ON cm.id_provee = pv.id_provee "
cSql += "GROUP BY cm.id_compra_mas "
cSql += "ORDER BY cm.com_fch_fac DESC" // SI QUITO "DESC" TRABAJA TODO BIEN
XBrowse / TDolphin
- Code: Select all Expand view
REDEFINE XBROWSE aBrw[2] ID 100 OF oFldx:aDialogs[2] ;
DATASOURCE oQryComPro ;
LINES CELL AUTOSORT AUTOCOLS ;
HEADERS "Cod.", "Nombre Proveedores", "Factura", "Fecha", "Kilos Compra" ,;
"Cant.Piezas";
COLUMNS "id_provee", "provee_nombres", "com_num_fac", "com_fch_fac" ,;
"com_peso_kilo", "com_unidades" ;
COLSIZES 50, 200, 50, 70, 80, 80 ;
JUSTIFY 2, , 2, 2 ;
PICTURES , , , , oPi:nKg1, oPi:nPi5