This is a migrated thread and some comments may be shown as answers.

oracle package function

9 Answers 89 Views
Databases and Data Types
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Henk
Top achievements
Rank 1
Henk asked on 29 Jun 2010, 04:28 PM
Hi,

I have the following scenario:

In a SL screen we have 3 controls: zip code, streetname and city.

We want when a user enter a zip code automatically the streetname and city are filled.
We have created different functions in an oracle package
a function with in parameter zipcode and return value streetname
a function with in parameter zipcode and return value city
a check function with in parameters streetname and city returns 0 or 1 (0=when combination street+city does not correspond with the zipcode etc.)

How to do this with ORM? Are there examples how to accomplish the above scenario?

Regards,

Henk


9 Answers, 1 is accepted

Sort by
0
Ady
Telerik team
answered on 05 Jul 2010, 10:33 AM
Hello Henk,

Although the OpenAccess Reversemapping wizard will read Oracle procedures and functions defined within a package, the runtime can execute only stored procedures. Adding support for functions is on our list and we will work on that after the Q2 release.
Is it possible for you to have similar functionality via a stored procedure and the return value can be mapped to an OUT parameter. You can then reverse map these procedures to create static methods, which can be used to execute the procedures and obtain the required values.

You can find more information about executing stored procedures, here.

Regards,
Ady
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Henk
Top achievements
Rank 1
answered on 05 Jul 2010, 11:41 AM
Thanks,

We have solved it without using ORM. It would be nice if we can have the following scenario i.e. ORM provide a stored procedure wrapper and automatically you can use this like an internal C# method for validation or CRUD operation without extra coding.  For example if the stored proc return cursor(a collection) you should be able to connect directly to a Telerik control without any coding. Our experience about object mappers are that they not easy to use and makes coding more complex and cumbersome and definitely not RAD especially when programming for Silverlight. We see that Telerik are progressing making coding easier using ORM. (aka WCF wizard) and to me using an Object mapper gives only advantages when it support RAD programming...

Henk
0
Ady
Telerik team
answered on 08 Jul 2010, 02:51 PM
Hello Henk,

 Thank you for your input. Currently you can map you own stored procedure for CUD operations. OpenAccess will then use the specified stored procedure instead of generating dynamic SQL. Regarding read operations, in order to perform lazy loading dynamic SQL needs to be generated. If a procedure returns ID fields of a certain persistent class, then a static method can be generated that returns a generic IEnumerable of that class.


Sincerely yours,
Ady
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
shortie
Top achievements
Rank 2
answered on 09 Nov 2010, 09:18 AM
Hello support,

We encountered this problem today. Do you have any updates for this thread?
Thanks in advanced.

Best regards,
shortie
0
Ady
Telerik team
answered on 12 Nov 2010, 10:58 AM
Hi ChunChang,

 Can you describe your exact problem and what you would like to achieve? As pointed out earlier you can instruct OpenAccess to create stored procedures to perform CUD operations and these are then used by the OpenAccess runtime.

All the best,
Ady
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Henk
Top achievements
Rank 1
answered on 03 Sep 2012, 10:49 AM
Hi,

I still see that ORM still does NOT support (Oracle) stored functions? "we will work on that after the Q2 release" is a very flexible statement ;-) It is not efficient to copy a function to a stored procedure for the same functionality only because ORM does not support functions...

I am very pleased that in each new release ORM making development easier by generating more and more code behind the scenes..

Regards,

Henk
0
Ady
Telerik team
answered on 06 Sep 2012, 10:58 AM
Hello Henk,

 I apologize for the incovenience caused. The reason this has not made it into the product yet is that we have not had enough customer requests for it so far. Other freqeuntly demanded feature requests have take priority.
We will re-evaluate the priority for this feature after Q3 2012 and will update this thread accordingly.
Do get back in case you need further assistance.

All the best,
Ady
the Telerik team
Follow @OpenAccessORM Twitter channel to be the first one to get the latest updates on new releases, tips and tricks and sneak peeks at our product labs!
0
Quynh
Top achievements
Rank 1
answered on 23 Jun 2014, 11:39 PM
Hello,
I wonder if we have the support for oracle package function yet?
0
Ralph Waldenmaier
Telerik team
answered on 24 Jun 2014, 07:56 AM
Hi Quynh,
Unfortunately, the only way at the moment is to use the Low Level ADO.API.

To raise the priority of this feature I have created a feature request here where we will review it and other clients will be able to up-vote it in order to push it to the top of our priority list.

Feel free to ask in case you have any other question.

Regards,
Ralph Waldenmaier
Telerik
 
OpenAccess ORM is now Telerik Data Access. For more information on the new names, please, check out the Telerik Product Map.
 
Tags
Databases and Data Types
Asked by
Henk
Top achievements
Rank 1
Answers by
Ady
Telerik team
Henk
Top achievements
Rank 1
shortie
Top achievements
Rank 2
Quynh
Top achievements
Rank 1
Ralph Waldenmaier
Telerik team
Share this question
or