FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour FiveDBU with ADO support
Posts: 1303
Joined: Tue Jul 21, 2009 08:12 AM
Re: FiveDBU with ADO support
Posted: Sat May 11, 2013 04:41 PM

Antonio,

Can you please show us how to work with MySQL?.

Thanks.

Muchas gracias. Many thanks.



Un saludo, Best regards,



Harbour 3.2.0dev, Borland C++ 5.82 y FWH 13.06 [producci贸n]



Implementando MSVC 2010, FWH64 y ADO.



Abandonando uso xHarbour y SQLRDD.
Posts: 1195
Joined: Mon Oct 17, 2005 05:41 AM
Re: FiveDBU with ADO support
Posted: Sat May 11, 2013 05:16 PM
lucasdebeltran wrote:Antonio,

Can you please show us how to work with MySQL?.

Thanks.


Lucas,

Here is an example for MySQL




Regards,

Marc



FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Posts: 1303
Joined: Tue Jul 21, 2009 08:12 AM
Re: FiveDBU with ADO support
Posted: Sat May 11, 2013 05:43 PM

Hello,

And why not use

cStr := "Driver={MySQL ODBC 3.51 Driver};Server=dolphintest.sitasoft.net;" + ;
"Database=dolphin_man;User=test_dolphin;Password=123456;Option=3;"

oDL := FW_OpenAdoConnection( cStr )

?

Thanks.

Muchas gracias. Many thanks.



Un saludo, Best regards,



Harbour 3.2.0dev, Borland C++ 5.82 y FWH 13.06 [producci贸n]



Implementando MSVC 2010, FWH64 y ADO.



Abandonando uso xHarbour y SQLRDD.
Posts: 1303
Joined: Tue Jul 21, 2009 08:12 AM
Re: FiveDBU with ADO support
Posted: Sat May 11, 2013 05:53 PM
When adding a record to MySQL, I get:

Error description: (DOS Error -2147352567) WINOLE/1007 El valor de BOF o EOF es True, o el actual registro se elimin贸; la operaci贸n solicitada requiere un registro actual. (0x800A0BCD): ADODB.Recordset

Stack Calls
===========
Called from: => TOLEAUTO:MOVELAST( 0 )
Called from: fivedbu.prg => RSAPPENDBLANK( 533 )
Called from: fivedbu.prg => (b)ADOOPEN( 424 )
Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:CLICK( 466 )
Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:LBUTTONUP( 657 )
Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1719 )
Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:HANDLEEVENT( 1409 )
Called from: .\source\classes\WINDOW.PRG => _FWH( 3182 )
Called from: => WINRUN( 0 )
Called from: .\source\classes\WINDOW.PRG => TMDIFRAME:ACTIVATE( 995 )
Called from: fivedbu.prg => MAIN( 65 )



RSAPPENDBLANK( 533 )

Code (fw): Select all Collapse
 聽 oRS:MoveLast()



The table is empty.
Muchas gracias. Many thanks.



Un saludo, Best regards,



Harbour 3.2.0dev, Borland C++ 5.82 y FWH 13.06 [producci贸n]



Implementando MSVC 2010, FWH64 y ADO.



Abandonando uso xHarbour y SQLRDD.
Posts: 1195
Joined: Mon Oct 17, 2005 05:41 AM
Re: FiveDBU with ADO support
Posted: Sat May 11, 2013 05:57 PM
lucasdebeltran wrote:Hello,

And why not use

cStr := "Driver={MySQL ODBC 3.51 Driver};Server=dolphintest.sitasoft.net;" + ;
"Database=dolphin_man;User=test_dolphin;Password=123456;Option=3;"

oDL := FW_OpenAdoConnection( cStr )

?

Thanks.


That was used in the previous version. I like that one also more, but Antonio changed it like this (whitch is also nice)
Maybe it would be better to have the 2 options to connect to ADO.
Like this or with a connection-string
Regards,

Marc



FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: FiveDBU with ADO support
Posted: Sat May 11, 2013 07:32 PM

Lucas,

We could use both ways. Creating an ODBC datasource from Windows and using it from FiveDBU seems a good way to avoid errors, but if you know the connection string for sure, then it is simpler than going the other way.

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: FiveDBU with ADO support
Posted: Mon May 13, 2013 08:45 AM
regards, saludos

Antonio Linares
www.fivetechsoft.com

Continue the discussion