Statistic Class
The Statistic class represents a SQL Server statistic counter.
Namespace: Microsoft.SqlServer.Management.Smo
Assembly: Microsoft.SqlServer.Smo (in Microsoft.SqlServer.Smo.dll)
Syntax
'Declaration
<EvaluationModeAttribute(AutomatedPolicyEvaluationMode.CheckOnSchedule)> _
<PhysicalFacetAttribute> _
Public NotInheritable Class Statistic _
Inherits ScriptNameObjectBase _
Implements ICreatable, IDroppable, IMarkForDrop, IScriptable
'Usage
Dim instance As Statistic
[EvaluationModeAttribute(AutomatedPolicyEvaluationMode.CheckOnSchedule)]
[PhysicalFacetAttribute]
public sealed class Statistic : ScriptNameObjectBase,
ICreatable, IDroppable, IMarkForDrop, IScriptable
[EvaluationModeAttribute(AutomatedPolicyEvaluationMode::CheckOnSchedule)]
[PhysicalFacetAttribute]
public ref class Statistic sealed : public ScriptNameObjectBase,
ICreatable, IDroppable, IMarkForDrop, IScriptable
[<SealedAttribute>]
[<EvaluationModeAttribute(AutomatedPolicyEvaluationMode.CheckOnSchedule)>]
[<PhysicalFacetAttribute>]
type Statistic =
class
inherit ScriptNameObjectBase
interface ICreatable
interface IDroppable
interface IMarkForDrop
interface IScriptable
end
public final class Statistic extends ScriptNameObjectBase implements ICreatable, IDroppable, IMarkForDrop, IScriptable
Remarks
To get Statistic object properties, users can be a member of the public fixed server role.
To set Statistic object properties, users must have ALTER permission on the parent table or view or be a member of the db_owner fixed database role.
To create or drop a statistics counter, users must have ALTER permission on the parent table or view or be a member of the db_owner fixed database role.
To update statistics, users must have ALTER permission on the parent table or view or be a member of the db_owner fixed database role.
Thread Safety
Any public static (Shared in Microsoft Visual Basic) members of this type are safe for multithreaded operations. Any instance members are not guaranteed to be thread safe.
Inheritance Hierarchy
System.Object
Microsoft.SqlServer.Management.Smo.SmoObjectBase
Microsoft.SqlServer.Management.Smo.SqlSmoObject
Microsoft.SqlServer.Management.Smo.NamedSmoObject
Microsoft.SqlServer.Management.Smo.ScriptNameObjectBase
Microsoft.SqlServer.Management.Smo.Statistic
Thread Safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
See Also