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

Execution of 'Microsoft.SqlServer.Types.SqlGeography:STIntersects(SqlGeography)' on the database server side currently not implemented.

4 Answers 112 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.
Dan
Top achievements
Rank 1
Dan asked on 29 Nov 2010, 09:52 PM
hello,

I am interested in using OpenAccess's new SQL Spatial type support, however, when testing this out with a query using the STIntersects method i get the following exception:

Execution of 'Microsoft.SqlServer.Types.SqlGeography:STIntersects(SqlGeography)' on the database server side currently not implemented.

does this mean that the new Spatial type support does not completely handle all the associated SQL Spatial methods?

my query is as follows:
     SampleGeographyDataEntityDiagrams dc = new SampleGeographyDataEntityDiagrams();
     SqlChars polygon = new SqlChars(new SqlString("POLYGON((" + userInputPoints + "))"));  // selection geometry
     var mapDataQuery = from c in dc.Countries
                        where c.GeographyData.STIntersects(SqlGeography.STGeomFromText(polygon, srid)).IsTrue
                        select c;

Note: at the moment I am just connecting to a sample DB running on the SQLExpress instance installed with Visual Studio 2010. 

Please let me know if this should work and/or what limitations are associated with the new SQL Spatial type support.
Thanks,
Dan

4 Answers, 1 is accepted

Sort by
0
Accepted
Thomas
Telerik team
answered on 30 Nov 2010, 05:20 PM
Hello Dan,

 at the moment, your observation is right: Linq support for methods on such types is not implemented yet. However, we are planning to include that in the next release (Q1 2011). As a workaround, you might want to consider the usage of direct SQL queries, which can include such SQL server methods.

Hope this helps,
Thomas
the Telerik team
Accelerate your learning with industry's first Telerik OpenAccess ORM SDK. Download today.
0
Dan
Top achievements
Rank 1
answered on 30 Nov 2010, 05:39 PM
Thanks for the quick response.

Guess I will stick with SQL queries for now and wait for the update next year.

Cheers,
Dan
0
Craig
Top achievements
Rank 1
answered on 16 Feb 2011, 04:54 PM
Any updates on this?  Really looking forward to spatial query capability...
0
Damyan Bogoev
Telerik team
answered on 21 Feb 2011, 05:08 PM
Hi Craig,

The Linq support for user defined methods is on our to-do list. We will try to implement it for the next Q1 release.
I am sorry for the inconvenience caused.

Best wishes,
Damyan Bogoev
the Telerik team
Tags
Databases and Data Types
Asked by
Dan
Top achievements
Rank 1
Answers by
Thomas
Telerik team
Dan
Top achievements
Rank 1
Craig
Top achievements
Rank 1
Damyan Bogoev
Telerik team
Share this question
or