Cuando hago el query (antes de definir el xbrowse) y le aplico un filtro a ese query, si hago
- Code: Select all Expand view RUN
- xbrowser oQry
me muestra correctamente el query con el fitro aplicado. PERO seguido a eso defino el xbrowser y el xbrowser ni se entera del filter
me muestra el query sin aplicarle el filtro.
#define BRW_PRODUCTOS ;
"SELECT " + ;
"a.id AS c1, " + ;
"s.nombre AS c2, " + ;
"n.nombre AS c3, " + ;
"d.nombre AS c4, " + ;
;
"s.id AS c10, " + ;
"d.id AS c11, " + ;
"t.stock as c12, " + ;
"t.stockminimo as c13 " + ;
;
"FROM tbprod AS a " + ;
;
"LEFT JOIN tbprodnom AS n ON n.id = a.idnombre " + ;
"LEFT JOIN tbdistribuidores AS d ON a.iddistribuidor = d.id " + ;
"LEFT JOIN tbsucursal AS s ON a.idsucursal = s.id " + ;
"LEFT JOIN tbstockres AS t ON t.idprod = a.id " + ;
;
"ORDER BY n.nombre "
- Code: Select all Expand view RUN
- ::oQry := ::oCnx:QUERY( BRW_PRODUCTOS )
::oQry:setfilter( "C10 = 1" )
::oQry:Requery()
xbrowser ::oQry // esto me muestra correctamente
DEFINE FONT oFont NAME "Ms Sans Serif" SIZE 0, - 18
DEFINE FONT oFont1 NAME "Ms Sans Serif" SIZE 0, - 16
DEFINE DIALOG oDlg RESOURCE "DLGBROWSER" TITLE ".: Productos :."
REDEFINE XBROWSE ::oBrw ID 107 OF oDlg ;
DATASOURCE ::oQry ;
autosort ;
COLUMNS "c1", "c2", "c3", "c4"