Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

NOW() in JQL

Dd
Contributor
April 30, 2025

Hi,

 

Is there a way to write a JQL statement asking if something happened 3 hrs. ago?

I tried NOW(-3h) and it won't accept parameters.

Thanks

Dd

2 answers

2 accepted

2 votes
Answer accepted
Tomislav Tobijas
Community Champion
April 30, 2025

Hi @Dd ,

Function now() doesn't accept relative offsets such as "-3h".

You could maybe use something like updated >= -3h (it kind of depends on the use case/requirement and what you're trying to achieve).
Or you could use something like startOfDay() instead. 👀

Cheers,
Tobi

Dd
Contributor
May 4, 2025

Relying on StartofDay() or EndofDay() was the direction I thought of but it's more constant 

The updated > -3h you mentioned looks interesting - I never knew I could do that. Thanks!

Any other fields that this applies?

Tomislav Tobijas
Community Champion
May 10, 2025

Hi @Dd ,

Yeah, you could use relative time expressions like "-3h", "-5d", etc. with system fields such as updated, createdresolved, duelastViewed but it should also work with custom date/time fields (if you use any).

Like • Dd likes this
0 votes
Answer accepted
Calvin
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 30, 2025

It sounds like you're looking for something more like:

  • updated > -3h

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events