List:General Discussion« Previous MessageNext Message »
From:Michael Widenius Date:November 28 1999 11:48am
Subject:Date Parameters and MyODBC
View as plain text  
>>>>> "Mamede" == Mamede DGM <mamede@stripped> writes:

Mamede> Hi All
Mamede> Some days ago I sent a message about using dates on criteries of SQL query.
Mamede>  Well, I readed everything I got but I
Mamede> did not find anything wrong with the options of MYODBC.
Mamede> I did set the trace of MYODBC to see what was going on and I got this code
Mamede> generated
Mamede> by MYODBC:

<cut>
Mamede> | >mysql_real_query
Mamede> | | enter: handle: 8ce2c
Mamede> | | query: Query = "SELECT Nome_do_Tipo , Nome , Fornecedor ,

Mamede>  Numero_do_Titulo , Tipo_do_Documento ,

Mamede>  Nota_Fiscal_de_Origem ,

Mamede>  Local_de_Cobranca , Data_da_Emissao ,

Mamede>  Data_do_Vencimento , Valor_do_titulo ,

Mamede>  Taxa_de_Permanencia ,

Mamede>  Pago ,

Mamede>  Data_do_Pagamento , Valor_Pago ,

Mamede>  Titulos_a_Pagar.Observacoes

Mamede> FROM Tipos_de_Documentos ,  Cadastro_Fabr_Forne ,

Mamede>   Titulos_a_Pagar
Mamede> WHERE ( Tipos_de_Documentos.Codigo_do_Tipo =
Mamede> Titulos_a_Pagar.Tipo_do_Documento )

Mamede>   AND

Mamede>  ( Cadastro_Fabr_Forne.Codigo = Titulos_a_Pagar.Fornecedor )

Mamede>   AND

Mamede>  (

Mamede>  ( ( Pago <>0 ) AND

Mamede>   ( Data_do_Pagamento Between 19980102000000 and 19981105000000 ) )

Mamede>  )

<cut>

Hi!

This is fixed in the latest MyODBC version;  There was a bug in
handling timestamp columns as parameters in the earlier MyODBC versions.

Regards,
Monty

PS: Sorry for the late reply;  I am still trying to catch up with the
    mails that piled up during my vacation.
Thread
Date Parameters and MyODBCMamede DGM2 Nov
  • Date Parameters and MyODBCMichael Widenius28 Nov