Update-NAVScheduledTaskList
Updates the application-wide list of scheduled tasks with the information from the tenant database.
Syntax
Update-NAVScheduledTaskList
[-ServerInstance] <String>
-Tenant <TenantId>
[-Force]
[-ProgressAction <ActionPreference>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Update-NAVScheduledTaskList
-ApplicationDatabaseServer <String>
-ApplicationDatabaseName <String>
[-ApplicationDatabaseCredentials <PSCredential>]
-DatabaseServer <String>
[-DatabaseName <String>]
[-DatabaseCredentials <PSCredential>]
[-Force]
[-ProgressAction <ActionPreference>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The task scheduler controls when certain operations or processes are run. Basically, a task is a codeunit or report that is scheduled to run at a specific data and time. Tasks run in a background session between the Business Central Server instance and database. Behind the scenes, the task scheduler is used by the job queue to process job queue entries that are created and managed from the clients.
Examples
Example 1
Update-NAVScheduledTaskList -ApplicationDatabaseServer MyAppDBServer -ServerInstance BC -Tenant Tenant1
This example updates the application database connected to the Business Central Server instance with the scheduled task information from Tenant1.
Parameters
-ApplicationDatabaseCredentials
Specifies the user name and password of the login account that the Business Central Server instance uses to access the application database in SQL Server when using SQL Server Authentication. This parameter is only relevant when you set with the ApplicationDatabaseServer and ApplicationDatabaseName parameters
Type: | PSCredential |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-ApplicationDatabaseName
Specifies the name of the database that is used by the tenant database. This parameter is only relevant if the Business Central Server instance is configured for multitenancy. This parameter, together with the ApplicationDatabaseServer parameter, enables you to update the application-wide list of scheduled tasks on a Business Central Server instance without having a running connection to the Business Central Server instance.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-ApplicationDatabaseServer
Specifies the name of the computer on which the SQL Server instance for the Business Central database that contains the application tables is installed in the multitenant deployment. Even if you are not importing application data to the application database, you must specify this parameter in a multitenant deployment.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Confirm
Prompts you for confirmation before running the cmdlet.
Type: | SwitchParameter |
Aliases: | cf |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-DatabaseCredentials
Specifies the user name and password of the login account that the Business Central Server instance will use to access the tenant database in SQL Server. This parameter configures the Business Central Server instance to use SQL Server Authentication instead of Windows Authentication on the connection to the database. The login account must be a member of the db_owner role on the database.
Type: | PSCredential |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-DatabaseName
Specifies the name of the tenant database that you want to update the application-wide list of scheduled task with.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-DatabaseServer
Specifies the name of the database server that hosts the tenant database that you want to update the global list scheduled tasks with.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Force
Forces the command to run without asking for user confirmation.
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ProgressAction
A common PowerShell parameter that determines how PowerShell responds to progress updates generated by a script, cmdlet, or provider. Learn more.
Type: | ActionPreference |
Aliases: | proga |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ServerInstance
Specifies the name of a Business Central Server instance, for example, BC or myinstance. You can specify either the full name of an instance, such as MicrosoftDynamicsNavServer$myinstance or the short name such as myinstance.
Type: | String |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Tenant
Specifies the ID of the tenant that you want to update the application-wide list of scheduled task with, such as Tenant1. A scheduled task in the tenant will be added to the application-wide list of scheduled tasks if it doesn't exist. This parameter is required unless the specified service instance is not configured to run multiple tenants.
Type: | TenantId |
Aliases: | Id |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Type: | SwitchParameter |
Aliases: | wi |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |