hmg and oracle

Creative ideas/suggestions for HMG

Moderator: Rathinagiri

User avatar
Ismach
Posts: 86
Joined: Wed Nov 28, 2012 5:55 pm
DBs Used: DBF, mySQL, Mariadb, postgreSQL, Oracle, Db2, Interbase, Firebird, and SQLite
Location: Buenos Aires - Argentina
Been thanked: 7 times

Re: hmg and oracle

Post by Ismach » Wed Nov 14, 2018 1:17 am

En el caso de que no funcionara hay que cambiar asi

Code: Select all

    oRs := TOleAuto():New("adodb.recordset")
    // oRs:ActiveConnection(oOra)[b][/b]
    // oRs:CursorLocation(3)
    // oRs:CursorType := adOpenStatic
    // oRs:CursorLocation := adUseClient
    // oRs:LockType := adLockOptimistic

    oRs:Open(cSQL, oOra)
    IF  oRs:RecordCount = 0

        MsgInfo( "Producto Caja de Seguridad Inexistente", SISTEMA )
        fmCajas.txtA0090.Setfocus
        RETURN NIL

    ENDIF

User avatar
Ismach
Posts: 86
Joined: Wed Nov 28, 2012 5:55 pm
DBs Used: DBF, mySQL, Mariadb, postgreSQL, Oracle, Db2, Interbase, Firebird, and SQLite
Location: Buenos Aires - Argentina
Been thanked: 7 times

Post by Ismach » Wed Nov 14, 2018 1:17 am

obvio que el esta demas

User avatar
Ismach
Posts: 86
Joined: Wed Nov 28, 2012 5:55 pm
DBs Used: DBF, mySQL, Mariadb, postgreSQL, Oracle, Db2, Interbase, Firebird, and SQLite
Location: Buenos Aires - Argentina
Been thanked: 7 times

Post by Ismach » Wed Nov 14, 2018 1:28 am

en el caso de que no funcione se ebe cambiar a:

Code: Select all

    oRs := TOleAuto():New("adodb.recordset")
    // oRs:ActiveConnection(oOra)
    // oRs:CursorLocation(3)
    // oRs:CursorType := adOpenStatic
    // oRs:CursorLocation := adUseClient
    // oRs:LockType := adLockOptimistic

    oRs:Open(cSQL, oOra )
    IF  oRs:RecordCount = 0

        MsgInfo( "Producto Caja de Seguridad Inexistente", SISTEMA )
        fmCajas.txtA0090.Setfocus
        RETURN NIL

    ENDIF
aguardo sus comentarios

User avatar
dragancesu
Posts: 614
Joined: Mon Jun 24, 2013 11:53 am
DBs Used: DBF, MySQL, Oracle
Location: Subotica, Serbia
Has thanked: 19 times
Been thanked: 116 times

Post by dragancesu » Wed Nov 14, 2018 1:32 pm

Thank you, I will try

Have you version with OCI?

User avatar
Ismach
Posts: 86
Joined: Wed Nov 28, 2012 5:55 pm
DBs Used: DBF, mySQL, Mariadb, postgreSQL, Oracle, Db2, Interbase, Firebird, and SQLite
Location: Buenos Aires - Argentina
Been thanked: 7 times

Post by Ismach » Wed Nov 14, 2018 1:40 pm

Nop! I don't use OCI,
I'm using WINOLE via ADODB ( conector nativo de windows )
provider="MSDAORA.1"

User avatar
Ismach
Posts: 86
Joined: Wed Nov 28, 2012 5:55 pm
DBs Used: DBF, mySQL, Mariadb, postgreSQL, Oracle, Db2, Interbase, Firebird, and SQLite
Location: Buenos Aires - Argentina
Been thanked: 7 times

Post by Ismach » Wed Nov 14, 2018 1:44 pm

more info : "Microsoft OLE DB Provider for Oracle Overview"
https://docs.microsoft.com/en-us/sql/ad ... erver-2017

User avatar
Ismach
Posts: 86
Joined: Wed Nov 28, 2012 5:55 pm
DBs Used: DBF, mySQL, Mariadb, postgreSQL, Oracle, Db2, Interbase, Firebird, and SQLite
Location: Buenos Aires - Argentina
Been thanked: 7 times

Post by Ismach » Wed Nov 14, 2018 1:46 pm

Lo que si se necesita es compilar las libs

c:\MiniGUI\SOURCE\HbOLE\
y
c:\MiniGUI\SOURCE\AdoRDD\

User avatar
dragancesu
Posts: 614
Joined: Mon Jun 24, 2013 11:53 am
DBs Used: DBF, MySQL, Oracle
Location: Subotica, Serbia
Has thanked: 19 times
Been thanked: 116 times

Post by dragancesu » Fri Dec 21, 2018 1:10 pm

I was try and work

Litlle problem is how solver NULL values from table

This is for MiniGUI !!! not for HMG
Attachments
orademo.zip
(1.95 KiB) Downloaded 41 times

User avatar
luisvasquezcl
Posts: 1127
Joined: Thu Jul 31, 2008 3:23 am
Location: Chile
Has thanked: 14 times
Been thanked: 14 times
Contact:

Post by luisvasquezcl » Fri Dec 21, 2018 5:01 pm

Estimados,
Como aporte al demo de dragancesu, para cargar datos más rápido que recorrer un bucle pueden hacerlo de la siguiente forma:

Dear,
As a contribution to the demo of dragancesu, to load data faster than going through a loop can do it in the following way:

Code: Select all

oRs := Openrecordset(oConexion, "Select * from customer")
aDatos := {}
if oRs:RecordCount > 0
    aDatos	:= oRs:getRows()
endif
oRs:close()
Best regards,
Luis Vasquez

User avatar
dragancesu
Posts: 614
Joined: Mon Jun 24, 2013 11:53 am
DBs Used: DBF, MySQL, Oracle
Location: Subotica, Serbia
Has thanked: 19 times
Been thanked: 116 times

Post by dragancesu » Fri Dec 21, 2018 6:28 pm

Hello luisvasquezcl,
can you send all program

I was try your way, but not work

Post Reply