This document is archived and information here might be outdated. Recommended version. |
ArcObjects namespaces > Geodatabase > ESRI.ArcGIS.GeoDatabase > Interfaces > IF > IFeatureWorkspace Interface > IFeatureWorkspace.OpenFeatureQuery Method (ArcObjects .NET 10.4 SDK) |
Opens a feature dataset containing a single feature class defined by the specified Query.
[Visual Basic .NET] Public Function OpenFeatureQuery ( _ ByVal QueryName As String, _ ByVal QueryDef As IQueryDef _ ) As IFeatureDataset
[C#] public IFeatureDataset OpenFeatureQuery ( string QueryName, IQueryDef QueryDef );
[C++]
HRESULT OpenFeatureQuery(
BSTR QueryName,
IQueryDef* QueryDef,
IFeatureDataset** FeatureDataset
);
[C++]
Parameters QueryName [in] QueryName is a parameter of type BSTR QueryDef [in]
QueryDef is a parameter of type IQueryDef FeatureDataset [out, retval]
FeatureDataset is a parameter of type IFeatureDataset
The OpenFeatureQuery can be used to open a virtual feature class whose definition is based on a QueryDef created using the CreateQueryDef method. The QueryDef can involve multiple tables as long as one of them is a feature class; the resulting virtual feature class can be used to construct a feature layer that can be added to a map. The shape column is required as part of the SubFields parameter of the QueryDef.