eSQL

Discussion of open issues, suggestions and bugs regarding Entity Framework support in ADO.NET Data providers
Post Reply
ies
Posts: 26
Joined: Thu 26 Feb 2009 08:10

eSQL

Post by ies » Fri 03 Apr 2009 09:34

Hi, i'm using eSQL and i have two questions

1.- ?Is possible use UPPER clause?

2.- ?Is possible use CONVERT clause? i want to convert numeric field to string

"SELECT a.FIELD1,a.FIELD2
FROM TABLE as a"

thanks,
________
MERCEDES-BENZ 300SL
Last edited by ies on Thu 24 Feb 2011 06:05, edited 1 time in total.

AndreyR
Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Post by AndreyR » Fri 03 Apr 2009 11:28

Both UPPER and CONVERT functions can be used in Entity SQL for Oracle.
Please note that you should use prefix "Devart.Data.Oracle", like in the following example:

Code: Select all

ObjectQuery query = new ObjectQuery("Devart.Data.Oracle.UPPER('hello')", context);

ies
Posts: 26
Joined: Thu 26 Feb 2009 08:10

Post by ies » Mon 06 Apr 2009 11:33

Hi Andrey,

?Can you write a sample using convert?

thanks,
________
Vermont Marijuana Dispensaries
Last edited by ies on Thu 24 Feb 2011 06:05, edited 1 time in total.

AndreyR
Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Post by AndreyR » Mon 06 Apr 2009 14:23

Here it goes

Code: Select all

ObjectQuery query = new ObjectQuery("Devart.Data.Oracle.CONVERT('Ä Ê Í Ó Ø A B C D E', 'US7ASCII')", context);

ies
Posts: 26
Joined: Thu 26 Feb 2009 08:10

Post by ies » Mon 06 Apr 2009 16:18

Hi Andrey,

Thanks for your reply. But i have a table with numeric field and i want to convert a numeric value to varchar value, example

TABLE1
FIELD1 VARCHAR2(50)
FIELD2 NUMERIC

I want to do:
"SELECT t.FIELD1,t.FIELD2 from context.TABLE1 as t
WHERE Devart.Data.Oracle.CONVERT(t.FIELD2, 'US7ASCII') like '%a%'"

"No overload of function 'Devart.Data.Oracle.CONVERT' is compatible with the argument types in 'Devart.Data.Oracle.CONVERT(Edm.Int32, Edm.String)'., near function 'CONVERT()'
?Is possible use TO_CHAR?

thanks,
________
GENETICALLY MODIFIED FOOD
Last edited by ies on Thu 24 Feb 2011 06:05, edited 1 time in total.

AndreyR
Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Post by AndreyR » Tue 07 Apr 2009 12:33

The TO_CHAR function is supported.
We will include the full list of supported functions to our documentation.

Post Reply