Reference

Endpoint Read Comments


Name

get_comments

Description

No description available

Related Tables

Comments

Parameters

Parameter Required Options
Name: Fields

Label: Fields

Name: Key

Label: Issue Key(s) or Ids - Comma Separated (PRJA-10,PRJA-13)

Use comma separated IDs or Keys for Issues. 1000 ids max or JIRA internal limit for Payload.
Name: SearchBy

Label: Search by

Option Value
None
Project Key(s) Project
JQL Expression JQL
Issue Id(s) or Key(s) Key
Name: Project

Label: Project Key(s) - Comma Separated (CBS,BRK)

Specify a project to search issues for
Name: JQL

Label: JQL Expression (For Issue Search)

Use JQL to use an advanced mode of searching. Few links are https://www.atlassian.com/blog/jira/jql-the-most-flexible-way-to-search-jira-14 and als check https://wac-cdn.atlassian.com/dam/jcr:241d9c9b-475f-411f-90a2-97ca344442b3/atlassian-jql-cheat-sheet-2.pdf?cdnVersion=2169
Option Value
Search Ids (IN) key IN(10001, 10002, 10003)
Search Keys (IN) key IN(CS-1, CS-2, CS-3)
Search Projects (IN) project IN(PROJ1, PROJ2, PROJ3)
Search Status (EQUAL) status='Done'
Search Date (Expression 1) created >=-5d
Search Date (Expression 2) created >=startOfMonth() AND created <=now()
Search Date (Expression 3) created >=startOfYear() AND created <=startOfDay()
Search Date (Expression 4 - Site Timezone) created >= '2008-12-31 23:59'
Search Date (Issue Created After Date - Quote1) created >= '2008-12-31'
Search Date (Issue Created After Date - Quote2) created >= "2008-12-31"
Search Date (Issue Created After Date+Time - Site Timezone) created >= '2008-12-31 23:59'
Search Date (Issue Updated After Date+Time - Site Timezone) updated >= "2008-12-31 23:59"
Search Date (Issue Updated In Last 5 Days) updated >=-5d
Search Date (Issue Updated In Last 24 Hours) updated >=-24h
Search Date (Worklog Created or Updated After Date) worklogDate >= '2008-12-31'
Search Date (Worklog Created or Updated In Last 2 Days) worklogDate >= -2d
Search Date (Worklog Created or Updated After for Specified Projects) project IN (PROJ1, PROJ2) AND worklogDate >= '2008-12-31'
Search Project and Status (AND + IN) project=CS AND status NOT IN ('Done', 'Open', 'Closed')
Search Assignee and Created Date assignee is NOT EMPTY and created < -1d
Search Text (Contains - Fuzzy) Summary ~ 'some words' OR description ~ 'some words'
Search Text (Contains - Fuzzy Wildcard) Summary ~ 'some*' OR description ~ 'some*'
Search Text (Contains - Exact) Summary ~ '\"exact words\"' OR description ~ '\"exact words\"'
Search Text (Does Not Contain - Fuzzy) Summary !~ 'some words' OR description !~ 'some words'
Search Empty OR Null fixVersion is empty OR fixVersion is null
Search Is Not Empty OR Is Not Null fixVersion is not empty OR fixVersion is not null
Search WAS Operator (previous value) status WAS "Resolved" BY (jsmith,srogen) BEFORE "2019/02/02"
Search WAS IN Operator status WAS IN ("Resolved", "In Progress")
Search WAS NOT IN Operator status WAS NOT IN ("Resolved", "In Progress")
Search WAS + BY + DURING (date range) status WAS "Resolved" BY (jsmith,srogen) DURING("2019/02/02", "2020/02/02")
Search CHANGED operator assignee CHANGED
Search CHANGED operator (multiple) status CHANGED FROM "In Progress" TO "Open"
Name: CustomColumnsRegex

Label: CustomColumnsRegex

Enter regular expression for custom columns which you like to output. Use Pipe to type multiple column names (must use key - internal names for columns e.g. customfield_10004). You can use Regex too (e.g. field_100\d+ ). This filter is only applied for those fields which has flag custom=true.

Output Columns

Label Data Type (SSIS) Data Type (SQL) Length Description
IssueId DT_WSTR nvarchar(20) 20
IssueKey DT_WSTR nvarchar(50) 50
Id DT_WSTR nvarchar(20) 20
Created DT_DBTIMESTAMP datetime
Updated DT_DBTIMESTAMP datetime
Self DT_WSTR nvarchar(150) 150
BodyType DT_WSTR nvarchar(50) 50
BodyContent DT_NTEXT nvarchar(MAX)
BodyContentText DT_NTEXT nvarchar(MAX) Join formatted text blocks using space separator (new lines will be lost)
BodyVersion DT_NUMERIC decimal(18,5)
AuthorSelf DT_WSTR nvarchar(150) 150
AuthorAccountId DT_WSTR nvarchar(100) 100
AuthorEmailAddress DT_WSTR nvarchar(100) 100
AuthorAvatarUrls48x48 DT_WSTR nvarchar(500) 500
AuthorAvatarUrls24x24 DT_WSTR nvarchar(500) 500
AuthorAvatarUrls16x16 DT_WSTR nvarchar(500) 500
AuthorAvatarUrls32x32 DT_WSTR nvarchar(500) 500
AuthorDisplayName DT_WSTR nvarchar(100) 100
AuthorActive DT_BOOL bit
AuthorTimeZone DT_WSTR nvarchar(100) 100
AuthorAccountType DT_WSTR nvarchar(50) 50
UpdateAuthorSelf DT_WSTR nvarchar(150) 150
UpdateAuthorAccountId DT_WSTR nvarchar(50) 50
UpdateAuthorEmailAddress DT_WSTR nvarchar(100) 100
UpdateAuthorAvatarUrls48x48 DT_WSTR nvarchar(500) 500
UpdateAuthorAvatarUrls24x24 DT_WSTR nvarchar(500) 500
UpdateAuthorAvatarUrls16x16 DT_WSTR nvarchar(500) 500
UpdateAuthorAvatarUrls32x32 DT_WSTR nvarchar(500) 500
UpdateAuthorDisplayName DT_WSTR nvarchar(100) 100
UpdateAuthorActive DT_BOOL bit
UpdateAuthorTimeZone DT_WSTR nvarchar(44) 44
UpdateAuthorAccountType DT_WSTR nvarchar(36) 36
jsdPublic DT_BOOL bit
If the column you are looking for is missing, consider customizing Jira Connector.

Input Columns

Label Data Type (SSIS) Data Type (SQL) Length Description
There are no Static columns defined for this endpoint. This endpoint detects columns dynamically at runtime.

Examples

SSIS

Use Jira Connector in API Source or in API Destination SSIS Data Flow components to read or write data.

API Source

This Endpoint belongs to the Comments table, therefore it is better to use it, instead of accessing the endpoint directly:

API Source - Jira
Read and write Jira data effortlessly. Track, manage, and automate issues, projects, worklogs, and comments — almost no coding required.
Jira
Comments
Optional Parameters
Fields id,key
Issue Key(s) or Ids - Comma Separated (PRJA-10,PRJA-13)
SSIS API Source - Read from table or endpoint

API Destination

This Endpoint belongs to the Comments table, therefore it is better to use it, instead of accessing the endpoint directly. Use this table and table-operation pair to read comments:

API Destination - Jira
Read and write Jira data effortlessly. Track, manage, and automate issues, projects, worklogs, and comments — almost no coding required.
Jira
Comments
Select, Lookup
Optional Parameters
Fields id,key
Issue Key(s) or Ids - Comma Separated (PRJA-10,PRJA-13)
SSIS API Destination - Access table operation

ODBC application

Use these SQL queries in your ODBC application data source:

Read comments for all issues

<p>Gets every comment across all issues. Use this when you need a flat list of all comments. To limit by issue, use the following examples that filter by issue ID or Key, or by JQL.</p>

SELECT * FROM Comments

Read comments for an issue by Key

<p>Gets all comments for a single issue identified by its key (e.g. CS-1).</p>

SELECT * FROM Comments WITH(Key='CS-1')

Read comments for issues by JQL

<p>Gets all comments for issues that match a JQL expression. The connector first finds issues with the given JQL, then returns comments for those issues. Use the same JQL syntax as in the “Read issues using JQL query” example.</p>

SELECT * FROM Comments WITH (Jql='status IN (Done, Closed) AND created > -5d' )

Read comments for an issue by ID or Key

<p>Gets all comments for one issue. Identify the issue by <code>IssueId</code> in the <code>WHERE</code> clause or by <code>Key</code> in <code>WITH</code>.</p>

SELECT * FROM Comments Where IssueId=10003 --OR WITH(Key='10003')

get_comments endpoint belongs to Comments table(s), and can therefore be used via those table(s).

SQL Server

Use these SQL queries in SQL Server after you create a data source in Data Gateway:

Read comments for all issues

<p>Gets every comment across all issues. Use this when you need a flat list of all comments. To limit by issue, use the following examples that filter by issue ID or Key, or by JQL.</p>

DECLARE @MyQuery NVARCHAR(MAX) = 'SELECT * FROM Comments';

EXEC (@MyQuery) AT [LS_TO_JIRA_IN_GATEWAY];

Read comments for an issue by Key

<p>Gets all comments for a single issue identified by its key (e.g. CS-1).</p>

DECLARE @MyQuery NVARCHAR(MAX) = 'SELECT * FROM Comments WITH(Key=''CS-1'')';

EXEC (@MyQuery) AT [LS_TO_JIRA_IN_GATEWAY];

Read comments for issues by JQL

<p>Gets all comments for issues that match a JQL expression. The connector first finds issues with the given JQL, then returns comments for those issues. Use the same JQL syntax as in the “Read issues using JQL query” example.</p>

DECLARE @MyQuery NVARCHAR(MAX) = 'SELECT * FROM Comments WITH (Jql=''status IN (Done, Closed) AND created > -5d'' )';

EXEC (@MyQuery) AT [LS_TO_JIRA_IN_GATEWAY];

Read comments for an issue by ID or Key

<p>Gets all comments for one issue. Identify the issue by <code>IssueId</code> in the <code>WHERE</code> clause or by <code>Key</code> in <code>WITH</code>.</p>

DECLARE @MyQuery NVARCHAR(MAX) = 'SELECT * FROM Comments Where IssueId=10003 --OR WITH(Key=''10003'')';

EXEC (@MyQuery) AT [LS_TO_JIRA_IN_GATEWAY];

get_comments endpoint belongs to Comments table(s), and can therefore be used via those table(s).