[mapguide-users] Select Distinct QueryOption or Filter?

Traian Stanev traian.stanev at autodesk.com
Tue Dec 5 22:04:42 EST 2006


 
You should use MgFeatureService::SelectAggregates() to do a distinct select.
In the FeatureAggregateOptions object that is passed as argument to that call, make sure you set the distinct flag by calling MgFeatureAggregateOptions::SelectDistinct(true).
 
Traian
 

	-----Original Message----- 
	From: Scott Reisdorf [mailto:reisdorf1 at llnl.gov] 
	Sent: Tue 12/5/2006 7:28 PM 
	To: users at mapguide.osgeo.org 
	Cc: 
	Subject: Re: [mapguide-users] Select Distinct QueryOption or Filter?
	
	

	Thanks Dave.
	I am using SDF3, and from the provider it says it supports
	SelectDistinct (<SupportsSelectDistinct>true</SupportsSelectDistinct> )
	I now dont know how to set the Flag in the QueryOptions to be Distinct. 
	Looking at the API and the code, it does not appear that the Distinct
	option is available on the QueryOptions.  Does anyone know how to select
	Distinct Features using the FeatureService?
	
	Thanks,
	-scott
	
	Dave Wilson wrote:
	> Not all providers support distinct.
	>
	> You need to check the GetCapabilities for each provider via
	> http://localhost/mapguide/mapagent/index.html under FeatureServices -
	> GetProviders will list your providers. Then using GetCapabilities it
	> will indicate if it supports Distinct. Distinct is a flag in the
	> QueryOptions that can be set if I recall correctly.
	>
	> Dave
	>
	> -----Original Message-----
	> From: Scott Reisdorf [mailto:reisdorf1 at llnl.gov]
	> Sent: Tuesday, December 05, 2006 2:50 PM
	> To: users at mapguide.osgeo.org
	> Subject: [mapguide-users] Select Distinct QueryOption or Filter?
	>
	> All,
	> Is there a way to query DISTINCT Features when using the
	> FeatureService.SelectFeatures() or SelectAggregrate() with the
	> QueryOptions, or possibly is there a "Distinct" filter option available.
	> Any help or code/source documenting this would be helpful.
	>
	> Thanks,
	>
	> -scott
	>
	>
	> ---------------------------------------------------------------------
	> To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
	> For additional commands, e-mail: users-help at mapguide.osgeo.org
	>
	>
	>
	> ---------------------------------------------------------------------
	> To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
	> For additional commands, e-mail: users-help at mapguide.osgeo.org
	>
	>  
	
	---------------------------------------------------------------------
	To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
	For additional commands, e-mail: users-help at mapguide.osgeo.org
	
	

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/mapguide-users/attachments/20061205/8075c18b/attachment.html


More information about the Mapguide-users mailing list