In order for this site to work correctly we need to store a small file (called a cookie) on your computer. Most every site in the world does this, however since the 25th of May 2011, by law we have to get your permission first. Please abandon the forum if you disagree.

Para que este foro funcione correctamente es necesario guardar un pequeño fichero (llamado cookie) en su ordenador. La mayoría de los sitios de Internet lo hacen, no obstante desde el 25 de Marzo de 2011 y por ley, necesitamos de su permiso con antelación. Abandone este foro si no está conforme.

Problem using MySql

Xailer professional forum in English
Responder
Milan Mehta
Mensajes: 140
Registrado: Dom Dic 27, 2009 9:54 am

Problem using MySql

Mensaje por Milan Mehta »

I have just upgraded from Professional to Enterprise Edition.
When I changed my DataSource from Ado to MySql, my working project started
giving me following error :
MYSQL : SHOW INDEX FROM (Select...
The error generated for all the TSqlQuerry:Open syntax.
Typically it goes like this :
cSql := 'SELECT party.partyname, tran.vdate, tran.vno, acmast.acname as
bankname, trim(tran.remarks) as remarks, tran.chequeno, acmast2.acname,
trtrn.amount as headamt, tran.amount, tran.tdsamount, tran.totamt'
cSql += ' from party, tran, acmast, acmast acmast2, trtrn '
cSql += ' where party.partycode = tran.partycode '
cSql += " and tran.compncode = " + LTrim(Str(AppData:XCMPCODE))
cSql += ' and tran.accode = acmast.accode '
cSql += ' and tran.compncode = trtrn.compncode '
cSql += ' and tran.book = trtrn.book '
cSql += ' and tran.vno = trtrn.vno '
cSql += " and tran.book = 'B'"
oSql := TSQLQuery():Create()
WITH OBJECT oSql
:oDataSource := Application:oMainForm:oAdo
IF :lOpen
:Close()
ENDIF
:cSelect := cSql
:Open()
END WITH
What am I doing wrong ?
TIA
Milan.
Avatar de Usuario
ignacio
Site Admin
Mensajes: 9443
Registrado: Lun Abr 06, 2015 8:00 pm
Ubicación: Madrid, Spain
Contactar:

Problem using MySql

Mensaje por ignacio »

Hello,
Could you send us the error.log?
Revise the property oMainForm:oAdo
BTW, consider user JOINS instead of:
from party, tran, acmast, acmast acmast2, trtrn '
Regards,
Ignacio Ortiz de Zúñiga
[OZ Software]
https://www.ozs.es
--
[Equipo de Xailer / Xailer team]
https://www.xailer.com
Milan Mehta
Mensajes: 140
Registrado: Dom Dic 27, 2009 9:54 am

Problem using MySql

Mensaje por Milan Mehta »

The error.log do not generate.
It is Xailer Data Control error as it shows in the attached snapshot.
It being a warning, the program still run on pressing Ok.
Setting the properly lDisplayError := .F. of MySqlDataSource, the warning
too do not display.
TIA
Milan.
"Ignacio Ortiz de Zúñiga" <nonametoavoidspam@xailer.com> wrote in
message news:52274f5a$[email=1@svctag-j7w3v3j....]1@svctag-j7w3v3j....[/email]
> Hello,
>
> Could you send us the error.log?
>
> Revise the property oMainForm:oAdo
>
> BTW, consider user JOINS instead of:
>
> from party, tran, acmast, acmast acmast2, trtrn '
>
> Regards,
> --
> Ignacio Ortiz de Zúñiga
> [Equipo de Xailer/Xailer team]
> http://www.xailer.com
> http://www.xailer.info


Attached files
Avatar de Usuario
ignacio
Site Admin
Mensajes: 9443
Registrado: Lun Abr 06, 2015 8:00 pm
Ubicación: Madrid, Spain
Contactar:

Problem using MySql

Mensaje por ignacio »

Hi,
Please, using the DB information on my previous sample. Try to reproduce your error. TIA.
Regards,
Ignacio Ortiz de Zúñiga
[OZ Software]
https://www.ozs.es
--
[Equipo de Xailer / Xailer team]
https://www.xailer.com
Responder