job_agents
Creates, updates, deletes, gets or lists a job_agents
resource.
Overview
Name | job_agents |
Type | Resource |
Id | azure.sql.job_agents |
Fields
- vw_job_agents
- job_agents
Name | Datatype | Description |
---|---|---|
database_id | text | field from the properties object |
jobAgentName | text | field from the properties object |
location | text | Resource location. |
resourceGroupName | text | field from the properties object |
serverName | text | field from the properties object |
sku | text | An ARM Resource SKU. |
state | text | field from the properties object |
subscriptionId | text | field from the properties object |
tags | text | Resource tags. |
Name | Datatype | Description |
---|---|---|
location | string | Resource location. |
properties | object | Properties of a job agent. |
sku | object | An ARM Resource SKU. |
tags | object | Resource tags. |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | jobAgentName, resourceGroupName, serverName, subscriptionId | Gets a job agent. |
list_by_server | SELECT | resourceGroupName, serverName, subscriptionId | Gets a list of job agents in a server. |
create_or_update | INSERT | jobAgentName, resourceGroupName, serverName, subscriptionId, data__location | Creates or updates a job agent. |
delete | DELETE | jobAgentName, resourceGroupName, serverName, subscriptionId | Deletes a job agent. |
update | UPDATE | jobAgentName, resourceGroupName, serverName, subscriptionId | Updates a job agent. |
SELECT
examples
Gets a list of job agents in a server.
- vw_job_agents
- job_agents
SELECT
database_id,
jobAgentName,
location,
resourceGroupName,
serverName,
sku,
state,
subscriptionId,
tags
FROM azure.sql.vw_job_agents
WHERE resourceGroupName = '{{ resourceGroupName }}'
AND serverName = '{{ serverName }}'
AND subscriptionId = '{{ subscriptionId }}';
SELECT
location,
properties,
sku,
tags
FROM azure.sql.job_agents
WHERE resourceGroupName = '{{ resourceGroupName }}'
AND serverName = '{{ serverName }}'
AND subscriptionId = '{{ subscriptionId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new job_agents
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure.sql.job_agents (
jobAgentName,
resourceGroupName,
serverName,
subscriptionId,
data__location,
location,
tags,
sku,
properties
)
SELECT
'{{ jobAgentName }}',
'{{ resourceGroupName }}',
'{{ serverName }}',
'{{ subscriptionId }}',
'{{ data__location }}',
'{{ location }}',
'{{ tags }}',
'{{ sku }}',
'{{ properties }}'
;
- name: your_resource_model_name
props:
- name: location
value: string
- name: tags
value: object
- name: sku
value:
- name: name
value: string
- name: tier
value: string
- name: size
value: string
- name: family
value: string
- name: capacity
value: integer
- name: properties
value:
- name: databaseId
value: string
- name: state
value: string
UPDATE
example
Updates a job_agents
resource.
/*+ update */
UPDATE azure.sql.job_agents
SET
tags = '{{ tags }}'
WHERE
jobAgentName = '{{ jobAgentName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND serverName = '{{ serverName }}'
AND subscriptionId = '{{ subscriptionId }}';
DELETE
example
Deletes the specified job_agents
resource.
/*+ delete */
DELETE FROM azure.sql.job_agents
WHERE jobAgentName = '{{ jobAgentName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND serverName = '{{ serverName }}'
AND subscriptionId = '{{ subscriptionId }}';