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

Table-values function support

9 Answers 108 Views
Getting Started
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Michel Corbin
Top achievements
Rank 1
Michel Corbin asked on 05 May 2010, 11:44 PM
Hi,

In many of my projects, I have a lot of queries that use table-values function and I want to know if OpenAccess have support with linq.

Thank you

9 Answers, 1 is accepted

Sort by
0
IT-Als
Top achievements
Rank 1
answered on 06 May 2010, 08:29 AM
Hi Samuel,

I don't know with LINQ, but we use CLR-UDF in a minimal set of our queries. We still query through the scope and get persistent instances back, but the query is written in SQL. This ensures that the full query is psuhed directly to the server.
I don't think you can you can mix the query languages or do this in LINQ alone, unless OA detects a CLR-UDF as being such a thing and pushes it to the server.

Anyone from Telerik to elaborate on this one?

Regards

Henrik
0
PetarP
Telerik team
answered on 06 May 2010, 03:19 PM
Hi Samuel Tremblay,

Unfortunately currently table valued functions are not something that is supported by our LINQ implementation. The good news are that we are heavily investing time in our LINQ implementation and lots of missing functionality will be introduced with our next releases.

Kind regards,
Petar
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
Michel Corbin
Top achievements
Rank 1
answered on 07 May 2010, 12:46 AM
Finally, I will use functions (in c#) that returns IQueryable result. This function will have the parameters equivalent of my table-valued-function. Finally, I can create a linq query that use the result of the IQueryable function instead of the result of a table. With this, I have exactly the same result as table-valued-function except things like performance, security, etc... but in my view, this will satisfy my needs.

Thank you all.
0
IT-Als
Top achievements
Rank 1
answered on 07 May 2010, 07:36 AM
Hi Samuel,

Great solution to expose the TVF as an IQueryable.


0
PetarP
Telerik team
answered on 12 May 2010, 04:36 PM
Hello Samuel Tremblay,

Indeed that is a nice solution. We are happy that you have found your way around. Should you face any further difficulties please do not hesitate to contact us.

All the best,
Petar
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
sitefinitysteve
Top achievements
Rank 2
Iron
Veteran
answered on 24 Nov 2010, 01:46 AM
Hey There,
  Any update on the Linq Table Function support?

A project using these just hit me again

Steve
0
PetarP
Telerik team
answered on 26 Nov 2010, 05:30 PM
Hi Steve,

 We do not provide a direct support for table valued functions and Linq. Does the solution that Samuel provided does not work for you?

Greetings,
Petar
the Telerik team
Accelerate your learning with industry's first Telerik OpenAccess ORM SDK. Download today.
0
sitefinitysteve
Top achievements
Rank 2
Iron
Veteran
answered on 26 Nov 2010, 05:46 PM
Right I know you DON'T....but CAN you :)

That and SP mapping to objects types?
0
PetarP
Telerik team
answered on 01 Dec 2010, 12:47 PM
Hello Steve,

 We don't have plans for that functionality just yet. We do plan to provide stored procedures that are mappable to specific types (even projections) but that is something that will be available around Q1 2011.

Sincerely yours,
Petar
the Telerik team
Accelerate your learning with industry's first Telerik OpenAccess ORM SDK. Download today.
Tags
Getting Started
Asked by
Michel Corbin
Top achievements
Rank 1
Answers by
IT-Als
Top achievements
Rank 1
PetarP
Telerik team
Michel Corbin
Top achievements
Rank 1
sitefinitysteve
Top achievements
Rank 2
Iron
Veteran
Share this question
or