GMSC Discussions

GeoMedia Smart Client community discussion board is where you can create, contribute and share information and knowledge in regards to configuring as well as working with GeoMedia Smart Client. Find your answers, share your knowledge and help build a strong GeoMedia Smart Client community.
Showing results for 
Search instead for 
Do you mean 
Reply
Highlighted
Frequent Contributor
Posts: 109
Registered: ‎09-18-2018
Accepted Solution

Geomedia SmartClient doesn't recognize feature from database

Hi 

 

I have the following feature defined from the following query:

 

Select 
	  Geometry_SPA.STGeometryType() AS GeometryType
	  ,CASE  
       WHEN GEOMETRY_SPA.STGeometryType()  = 'Polygon' THEN 
			GEOMETRY_SPA.STCentroid()
          
       ELSE -- points
			 GEOMETRY_SPA.STStartPoint() 
            
       END AS GEOMETRY_SPA
	 
      ,CASE  
       WHEN GEOMETRY_SPA.STGeometryType()  = 'Polygon' THEN 
			[dbo].[SqlGeometry2Binary] ( GEOMETRY_SPA.STCentroid())

       ELSE -- points
		[dbo].[SqlGeometry2Binary] ( GEOMETRY_SPA.STStartPoint() )
            
       END AS [GEOMETRY]

	  FROM WHeritageCulture.dbo.Item

SqlGeometry2Binary converts but Geomedia SmartClient won't read it.

It works fine on Geomedia.

 

Any suggestion on how can make GMSC read my Geometry?

 

Cheers,

Highlighted
Frequent Contributor
Posts: 109
Registered: ‎09-18-2018

Re: Geomedia SmartClient doesn't recognize feature from database

 

As the SqlGeometry2Binary will convert into Native binary and not into Geomedia binary. So, if GMSC finds a Geometry column already filled  it will not read but if you give a NULL Column will do..

 

 

For this work you will need to add a Fake column: Geometry(VarBinary) as NULL.