First, search the help docs and this forum. Maybe your question has been answered! The debugging steps can help, too. Still stuck? Delete this line and proceed.
What I’m trying to do
Format the output in a Dataview table so that it shows the tenure of a colleague in Years, Months and Days (but excludes minutes, seconds and milliseconds).
Things I have tried
I have a note for each colleague where contains(notetype,"people). This ‘people’ note includes roles, area-of-work, joined (as date), etc. as inline metadata.
Then I have created a note for my department and I have created the following dataview table. This produces a list of colleagues, including their tenure (which is the duration between when they joined and the current date).
TABLE without ID file.name AS Name, Joined, date(now) - joined AS "Tenure", role AS Roles, module AS Modules
FROM !"X PKM"
WHERE contains(notetype,"people")
WHERE contains(this.file.inlinks, file.link)
WHERE left = false
SORT file.name ASC
Tenure works but provides minutes, seconds and miliseconds, as shown in this screenshot.

I have tried looking at the Dataview Git pages and this forum. I have also looked at luxon formating but cannot understand how to use this in the table query.