Wzaf,
What FWH version are you using ? Harbour or xHarbour, what version ?
Porting FW to FWH using MySql
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
- nageswaragunupudi
- Posts: 8017
- Joined: Sun Nov 19, 2006 5:22 am
- Location: India
- Contact:
Re: Porting FW to FWH using MySql
In case of MySql we are compelled to use ODBC driver. There is no free OLEDB provider available. The total functionality of ADO is not supported by ODBC. We need to work with these limitations while working with MySql. We can not expect whatever that works with Oracle, MSSql etc. will also work with MySql ODBC driver.
Regards
G. N. Rao.
Hyderabad, India
G. N. Rao.
Hyderabad, India
Re: Porting FW to FWH using MySql
Antonio,
I use FWH 10.1
Harbour for BCC - 2.0
Regards
Wzaf
I use FWH 10.1
Harbour for BCC - 2.0
Regards
Wzaf
- Daniel Garcia-Gil
- Posts: 2365
- Joined: Wed Nov 02, 2005 11:46 pm
- Location: Isla de Margarita
- Contact:
Re: Porting FW to FWH using MySql
Hello wzaf.
Try this way
Try this way
Code: Select all
#include "Fivewin.ch"
#include "ado.ch"
FUNCTION MAIN()
local oCon, lOk
lOk:=.t.
if lOk
TRY
oCon:=TOleAuto():new("ADODB.Connection")
CATCH oErroraDo
ErrorCatch( oErrorAdo, "Error en OLE" )
END
TRY
oCon:connectionString := "Driver={MySQL ODBC 5.1 Driver};Server=EQUIPO;Port=3306;Database=test;User=root; Password=12345678;Option=3;"
oCon:open()
CATCH oErrorAdo
ErrorCatch( oErrorAdo,"Error en OPEN" )
return .f.
END
endif
return nil
Function ErrorCatch( oError, cTitle )
LOCAL cMensagemRetorno := ""
local cArg, cArgs := ""
if ValType( oError:Args ) == "A"
for each cArg in oError:Args
cArgs += cValToChar( cArg ) + CRLF
NEXT
endif
cMensagemRetorno := "[Subsystem]" + oError:SubSystem + CRLF +;
"[SubCode]" + alltrim( str( oError:SubCode ) ) + CRLF +;
"[Operacion]" + oError:Operation + CRLF +;
"[Descripcion]" + oError:Description + CRLF +;
"[Argumentos]" + cArgs
RETURN( msgStop( cMensagemRetorno, cTitle ) )
our best documentation is the source code
Isla de Margarita Venezuela.
danielgarciagil@gmail.com
http://tdolphin.blogspot.com/
https://www.dropbox.com/referrals/NTI5N ... rc=global9
Isla de Margarita Venezuela.
danielgarciagil@gmail.com
http://tdolphin.blogspot.com/
https://www.dropbox.com/referrals/NTI5N ... rc=global9
Re: Porting FW to FWH using MySql
Tank you Daniel ! ,
it works .
Best Regards
Wzaf
it works .
Best Regards
Wzaf