Page 1 of 1

MySQL and Hector Pezoa library with OT4XB for MySQL

Posted: Thu Sep 26, 2013 8:21 am
by c-tec
Hello,
I use somtimes Hector Pezoa library with OT4XB for MySQL because I don't need to install a ODBC driver like in SQLEXPRESS. Now I would like to use the eXpress++ browser and DC_SQLFieldBlock(). But I see only the first line of a dataset. It seems that there is something different to SQLEXPRESS, maybe the skipper. Has anyone a solution for that ?
regards
Rudolf

Re: MySQL and Hector Pezoa library with OT4XB for MySQL

Posted: Mon Sep 30, 2013 3:30 pm
by MIGUELON
Hi Rudolf, do not know if this piece of code can help, I utiliz SOFTPRO SPSQL without ODBC

  @ 7.4,1 DCBROWSE oLineasCompraModificar data oAlbaranCTemp;
                       PRESENTATION DC_BrowPres ();
                         RBSELECT

 DCBROWSECOL FIELD oAlbaranCTemp:dataarea:CANTIDAD_P WIDTH 4 HEADER EE1[3] OBJECT oCantModificar ;
PARENT oLineasCompraModificar ;
picture pp1[3] lostfocus bLostFocus

Regards
Miguel

Re: MySQL and Hector Pezoa library with OT4XB for MySQL

Posted: Thu Oct 03, 2013 3:55 am
by c-tec
Hello,
I think the problem is not in the column objects, it seems to be the skipper, so in the oBrowse object. The column is shown correct so far, but only the first in the table.
regards
Rudolf

Re: MySQL and Hector Pezoa library with OT4XB for MySQL

Posted: Thu Oct 03, 2013 10:18 am
by Auge_Ohr
c-tec wrote:I use somtimes Hector Pezoa library with OT4XB for MySQL because I don't need to install a ODBC driver like in SQLEXPRESS. Now I would like to use the eXpress++ browser and DC_SQLFieldBlock(). But I see only the first line of a dataset. It seems that there is something different to SQLEXPRESS, maybe the skipper.
hm ... as i can say Hector do not use DATAREF for Resultset.

as i understand you need a Cursor to browse with DC_*

Code: Select all

FUNCTION DC_SQLFieldBlock( oCursor, nField )
RETURN {|x| iif(PCount()==0, oCursor:fieldGet(nField), ;
                             oCursor:fieldPut(nField, x))}
for Hectors LIB you must use his Table Method

Code: Select all

METHOD XbTable:Skip(nSkip)
METHOD XbTable:Skipper(nSkip)
METHOD XbTable:FieldGet(c)
METHOD XbTable:FieldPut(c, Value)
to build a Browse.

Re: MySQL and Hector Pezoa library with OT4XB for MySQL

Posted: Sun Oct 06, 2013 2:03 am
by c-tec
Hello Jimmy,
and this must be in the source of DCBROWSE, I will take a look into it. I think some changes in the class code of Hectors lib could solve the problem.
regards
Rudolf