Tasks
To Create, Update, Delete and Query from Tasks table.
Table Specific Information
Select
The 本製品 will use the Asana API to process WHERE clause conditions built with the following column and operator. The rest of the filter is executed client side within the 本製品.
- Id supports the '=' comparison.
- ProjectId supports the '=' comparison.
- Assignee supports the '=' comparison. Note : Assignee should always be provided with WorkspaceId, either in query or in connection string.
- TagId supports the '=' comparison.
- SectionId supports the '=' comparison.
- UserTaskListId supports the '=' comparison.
For example, the following queries are processed server side:
SELECT * FROM Tasks WHERE Id = '1127092449876457' SELECT * FROM Tasks WHERE ProjectId = '1128092964672848' SELECT * FROM Tasks WHERE Assignee = '1126938691750986' AND WorkspaceId = '1126938837961830' SELECT * FROM tasks WHERE TagId = '1129517083601713' SELECT * FROM tasks WHERE SectionId = '1127092449876457' SELECT * FROM tasks WHERE UserTaskListId = '1126938837961837'
When executing a query without one of the above filters, due to the Asana API design, tasks must be retrieved per project. The 本製品 will first query the
workspace to retrieve a list of projects. A separate request will then be made for each project to retrieve all the applicable tasks. In theory, this is similar
to executing the following query:
SELECT * FROM Tasks WHERE ProjectId IN (SELECT Id FROM Projects)Due to the number of required requests, performance may be impacted. Note, tasks may also be orphaned and not belong to a project. The 本製品 will not be able to retrieve orphaned tasks.
Insert
ProjectId is a mandatory column for inserting into Tasks table. For example:
INSERT INTO Tasks (Name, Assignee, AssigneeStatus, startOn, DueOn, Completed, ProjectId, Notes, ApprovalStatus, Followers) VALUES ('Task1', '1167715005778471', 'later', '2020-03-25', '2020-04-01', false, 1167713816822364, 'TaskNotes', 'changes_requested', '1167715005778471')
Update
Following is an example of how to update a Tasks table:
UPDATE Tasks SET Browser = 'ie' WHERE Id = '1167713816822371'
Delete
Following is an example of how to delete from Tasks table:
DELETE FROM Tasks WHERE Id = '1167713816822371'
Columns
Name | Type | ReadOnly | References | Description |
Id [KEY] | String | True |
Globally unique ID of the task. | |
Name | String | False |
Name of the task. | |
Assignee | String | False |
Users.Id |
User to which this task is assigned. |
AssigneeStatus | String | False |
Scheduling status of this task for the user it is assigned to. 使用できる値は次のとおりです。today, upcoming, later, new, inbox | |
CreatedAt | Datetime | True |
The time at which this task was created. | |
ModifiedAt | Datetime | True |
The time at which this task was last modified. | |
startOn | Date | False |
Date and time on which this task is due, or null if the task has no due time. | |
DueAt | Datetime | False |
Date and time on which this task is due, or null if the task has no due time. | |
DueOn | Date | False |
Date on which this task is due, or null if the task has no due date. This takes a date with YYYY-MM-DD format. | |
Completed | Boolean | False |
True if the task is currently marked complete, false if not. | |
CompletedAt | Datetime | True |
The time at which this task was completed, or null if the task is incomplete. | |
CompletedBy | String | True |
Users.Id |
The user who completed this task. |
ProjectId | String | False |
Projects.Id |
Projectid of this task is associated with. |
Projects | String | False |
Projects of this task is associated with. | |
WorkspaceId | String | False |
Workspaces.Id |
Globally unique ID of the Workspace. |
Notes | String | False |
More detailed, free-form textual information associated with the task. | |
NumberofSubTasks | Integer | True |
The number of subtasks on this task. | |
ApprovalStatus | String | False |
Reflects the approval status of this task. 使用できる値は次のとおりです。pending, approved, rejected, changes_requested | |
ResourceSubType | String | False |
The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. 使用できる値は次のとおりです。default_task, milestone, section, approval | |
HtmlNotes | String | False |
The notes of the text with formatting as HTML. | |
Memberships | String | True |
Array of projects this task is associated with and the section it is in. | |
Dependencies | String | True |
Array of resources referencing tasks that this task depends on. | |
Dependents | String | True |
Array of resources referencing tasks that depend on this task. | |
Liked | Boolean | True |
True if the task is liked by the authorized user, false if not. | |
NumberofLikes | Integer | True |
The number of users who have liked this Task. | |
LikedBy | String | True |
Array of likes for users who have liked this task. | |
ResourceType | String | True |
The base type of this resource. | |
IsRenderedAsSeparator | Boolean | True |
In some contexts tasks can be rendered as a visual separator. | |
Followers | String | False |
Array of users following this task. | |
Tags | String | False |
Array of tags associated with this task. | |
ActualTimeMinutes | Double | True |
This value represents the sum of all the Time Tracking entries in the Actual Time field on a given Task. It is represented as a nullable long value. Note: The time tracking feature is only available on the Asana Advanced or a higher subscription. | |
Parent | String | True |
The parent of this task, or null if this is not a subtask. | |
ItemURL | String | True |
A URL that points directly to the object within Asana. | |
External | String | False |
The external field allows you to store app-specific metadata on tasks, including a gid that can be used to retrieve tasks and a data blob that can store app-specific character strings. Note that you will need to authenticate with OAuth to access or modify this data. | |
AssigneeResourceType | String | True |
The base type of the Assignee resource. | |
AssigneeName | String | True |
The Assignee user's name. | |
AssigneeSection | String | False |
The assignee section is a subdivision of a project that groups tasks together in the assignee's 'My Tasks' list. The assignee_section property will be returned in the response only if the request was sent by the user who is the assignee of the task. | |
AssigneeSectionResourceType | String | True |
The base type of the AssigneeSection resource. | |
AssigneeSectionName | String | True |
The name of the The name of the section. | |
StartAt | Datetime | False |
Date and time on which work begins for the task, or null if the task has no start time. It should not be used together with startOn. | |
CompletedByResourceType | String | True |
The base type of the CompletedBy resource. | |
CompletedByName | String | True |
The CompletedBy user's name. | |
WorkspaceResourceType | String | True |
The base type of the Workspace resource. | |
WorkspaceName | String | True |
The name of the workspace. | |
SectionId | String | True |
Sections.Id |
PseudoColumn: Globally unique ID of the section. |
UserTaskListId | String | True |
WorkspaceMembership.UserTaskListId |
PseudoColumn: A user task list represents the tasks assigned to a particular user. |
TagId | String | True |
Tags.Id |
PseudoColumn: Globally unique ID of the tag. |