Problem with date literals...

Problem with date literals...

Hi, I was just doing a query, having my server date format set to DD-MM-YYYY, and, while trying to test it, the tester forced me to insert a date literal, which is in the form basically, the tester doesn't convert the date literal to the server format, or so it seems.

I just know the test output gets empty, on service studio, and not when I test it in sql enterprise....

Do you have any workarounds for this, or is it an "no workaround bug" ?

Thank you,


Diogo Cordeiro
Hi Diogo

The Test Query is a Service Studio feature and, as such, accepts literals in Service Studio literals language format. As you mentioned, this means that dates must be written as #yyyy-mm-dd#. The server date format is then used only to format back the retrieved values.

Please check the query parameter datatype. Assure it is set as Date and not as Text.
If you are using a Simple Query, you may also select the SQL tab in the Query Editor to check for the generated "pseudo-SQL" .

If you think it is a platform bug, please submit it to

António Melo
I've tried to test with a simple as well an advanced query, and it seems not to convert the date...

I've already sent a feedback to support.

Thank you for your reply.

Best regards,

Diogo Cordeiro
I just got a workaround, since my search is "date=date" i convert it to text, and it works.

I did the following:

I need  little help

i wanna make a search parameter whit the date like that:

FILIAL.Nome like "%" + SearchKeyword + "%" or FILIAL.Morada like "%" + SearchKeyword + "%" + "%" or FILIAL.Email like "%" + SearchKeyword + "%"

but i dont know how i do to write the date SearckKeyword, cause when i put FILIAL.Data_de_Nascimento like "%" + SearchKeyword + "%" is unacceptable....

Annyone can help me?

Gleydson Lopes
Hi Gleydson, and welcome to our community forums.

In SQL language, you can only use the like operator with text-type parameters. As such, having

FILIAL.Data_de_Nascimento like "%" + SearchKeyword + "%"

will not work, since Data_de_Nascimento is a date.

Probably what you're looking for is converting the Date to Text, by doing

FILIAL.Data_de_Nascimento) like "%" + SearchKeyword + "%"

But make sure that what you are trying to achieve is indeed covered by the like operator.

Best regards,

Paulo Tavares
it's work's thank u..

i've tried to teste whit another way
COLABORADORES.Data_de_Nascimento = TextToDate(SearchKeyword)

it's almost the same thing...

Thank you Paulo for your reply

Best regards,

Gleydson Lopes