SubscriptionConditionScheduledRule.InputTypeSchema Property
Gets or sets the database schema name for the table or view specified by the InputTypeName property.
Namespace: Microsoft.SqlServer.Management.Nmo
Assembly : Microsoft.SqlServer.Smo (in microsoft.sqlserver.smo.dll)
Syntax
'Declaration
Public Property InputTypeSchema As String
public string InputTypeSchema { get; set; }
public:
property String^ InputTypeSchema {
String^ get ();
void set (String^ value);
}
/** @property */
public String get_InputTypeSchema ()
/** @property */
public void set_InputTypeSchema (String value)
public function get InputTypeSchema () : String
public function set InputTypeSchema (value : String)
Eigenschaftswert
A String, between 1 and 128 characters in length, that specifies the schema name for the input table or view.
Hinweise
The default schema value is the application database schema, specified using the SchemaName property.
When you use a SubscriptionConditionScheduledRule object, you must specify which view or table contains the event data. This view or table is in a schema.
For event chronicles, the schema is defined in the CREATE TABLE statement that creates the event chronicle. This is usually the same as the application schema. For more information, see Definieren von Verläufen für eine Ereignisklasse.
For more information, see Definieren von Bedingungsaktionen.
Beispiel
The following examples show how to define a condition-based, scheduled subscription rule and add it to a subscription class:
// Add a rule to generate condition-based, scheduled notifications
SubscriptionConditionScheduledRule flightConditionScheduledRule =
new SubscriptionConditionScheduledRule(
flightSubscriptions, "FlightConditionScheduledRule");
flightConditionScheduledRule.ActionTimeout =
new TimeSpan(0, 2, 0);
flightConditionScheduledRule.SqlLoginName = "MyLowPrivLogin";
flightConditionScheduledRule.SqlUserName = "MyLowPrivUser";
flightConditionScheduledRule.InputTypeName = "FlightEventChronicle";
flightConditionScheduledRule.InputTypeSchema = "MyAppSchema";
flightConditionScheduledRule.SqlExpression =
"INSERT INTO MyAppSchema.FlightNotifications (SubscriberId, " +
"DeviceName, SubscriberLocale, LeavingFrom, GoingTo, Price) " +
"SELECT [Subscription.SubscriberId], " +
"[Subscription.DeviceName], [Subscription.SubscriberLocale], " +
"[Input.LeavingFrom], [Input.GoingTo], [Input.Price] " +
"FROM MyAppSchema.FlightConditionScheduledRule;";
flightSubscriptions.SubscriptionConditionScheduledRules.Add(
flightConditionScheduledRule);
' Add a rule to generate condition-based, scheduled notifications
Dim flightConditionScheduledRule As _
SubscriptionConditionScheduledRule = _
New SubscriptionConditionScheduledRule( _
flightSubscriptions, "FlightConditionScheduledRule")
flightConditionScheduledRule.ActionTimeout = _
New TimeSpan(0, 2, 0)
flightConditionScheduledRule.SqlLoginName = "MyLowPrivLogin"
flightConditionScheduledRule.SqlUserName = "MyLowPrivUser"
flightConditionScheduledRule.InputTypeName = _
"FlightEventChronicle"
flightConditionScheduledRule.InputTypeSchema = "MyAppSchema"
flightConditionScheduledRule.SqlExpression = _
"INSERT INTO MyAppSchema.FlightNotifications " + _
"(SubscriberId, DeviceName, SubscriberLocale, LeavingFrom, " + _
"GoingTo, Price) SELECT [Subscription.SubscriberId], " + _
"[Subscription.DeviceName], [Subscription.SubscriberLocale], " + _
"[Input.LeavingFrom], [Input.GoingTo], [Input.Price] " + _
"FROM MyAppSchema.FlightConditionScheduledRule;"
flightSubscriptions.SubscriptionConditionScheduledRules.Add( _
flightConditionScheduledRule)
Threadsicherheit
Any public static (Shared in Microsoft Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Plattformen
Entwicklungsplattformen
Eine Liste der unterstützten Plattformen finden Sie unterHardware- und Softwareanforderungen für die Installation von SQL Server 2005.
Zielplattforme
Eine Liste der unterstützten Plattformen finden Sie unterHardware- und Softwareanforderungen für die Installation von SQL Server 2005.
Siehe auch
Verweis
SubscriptionConditionScheduledRule Class
SubscriptionConditionScheduledRule Members
Microsoft.SqlServer.Management.Nmo Namespace
Andere Ressourcen
Definieren von geplanten Regeln
Definieren von Bedingungsaktionen
ScheduledRule Element (ADF)
ConditionAction Element (ADF)