web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

how to give a query range the value DateTimeUtil::minValue()

(0) ShareShare
ReportReport
Posted on by

I need to view salary related data in a form for all employee( both terminated & employed ). I create a query which has four data sources (HcmWorker, DirPerson, HcmEmployemnt and SalaryDetails /customizaed table ). I added ranges to HcmEmployemnt data source using the field Valid To . I need to give Valid To value such as DateTimeUtil::minValue() and use the relation greater than to get all employees (terminated & employed), how can I do this ?

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Bashir Ahmad Profile Picture
    5,248 on at

    Look in to this thread:

    community.dynamics.com/.../92473.aspx

    also can verify the syntax of the query:

    https://community.dynamics.com/ax/f/33/t/119489.aspx

  • Suggested answer
    Martin Dráb Profile Picture
    237,878 Most Valuable Professional on at

    HcmEmployment table contains date-effective data. Instead of using usual ranges, set values to Query.validTimeStateDateRange() or Query.validTimeStateDateTimeRange().

  • maram fraij Profile Picture
    on at

    The query is AOT query similar to that used with HcmWorkerListPage_PastWorkers

    How can I use validTimeStateDateTimeRange ?

  • Martin Dráb Profile Picture
    237,878 Most Valuable Professional on at

    You'll call the method and pass some parameters into it, e.g. query.validTimeStateDateTimeRange(DateTimeUtil::minValue(), DateTimeUtil::maxValue()).

    I thought you would know how to use these methods, because you mentioned DateTimeUtil::minValue() in your question.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Priya_K Profile Picture

Priya_K 4

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#3
Ali Zaidi Profile Picture

Ali Zaidi 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans