# SYSTIMESTAMP in @Function

**URL:** <https://discourse.hibernate.org/t/systimestamp-in-function/12447>\
**Category:** Hibernate ORM\
**Created:** [October 2, 2026, 6:44am UTC](https://discourse.hibernate.org/t/systimestamp-in-function/12447 "2026-10-02T06:44:34Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![zpneun](https://avatars.discourse-cdn.com/v4/letter/z/b2d939/32.png) [@zpneun](https://discourse.hibernate.org/u/zpneun)\
**Post date:** [October 2, 2026, 6:44am UTC](https://discourse.hibernate.org/t/systimestamp-in-function/12447/1 "2026-10-02T06:44:34Z")

</div>

Hello all,

once upon a time, Hibernate was able to detect database specific functions (like SYSTIMESTAMP) in @Function annotations. Today, for example with 7.4, this ability was removed. Those functions, if not suffixed by (), aren’t any longer detected as functions and therefore prefixed with the table alias (rendering in b1\_0.systimestamp, which is rejected by the database).

The reason for this I discovered lies in commit a20fb5663d titled “major rework of Template + battery of new tests” which removed the “isFunction” method from `org.hibernate.sql.Template` class which had been responsible to lookup the database specific function descriptors.

May I suppose this is a bug (in this case, I would create an Issue), or could it in any way be intended behaviour?

Marcus.

---

<div class="post-metadata">

**Author:** ![beikov](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.hibernate.org/beikov/32/258_2.png) [@beikov](https://discourse.hibernate.org/u/beikov)\
**Post date:** [October 8, 2026, 10:26am UTC](https://discourse.hibernate.org/t/systimestamp-in-function/12447/2 "2026-10-08T10:26:56Z")

</div>

I’d say that the `OracleDialect` should probably register such functions without parenthesis as “keywords”, such that `org.hibernate.sql.Template#isKeyword` would return `true` for `systimestamp` etc.

---

<div class="post-metadata">

**Author:** ![zpneun](https://avatars.discourse-cdn.com/v4/letter/z/b2d939/32.png) [@zpneun](https://discourse.hibernate.org/u/zpneun)\
**Post date:** [October 9, 2026, 4:13am UTC](https://discourse.hibernate.org/t/systimestamp-in-function/12447/3 "2026-10-09T04:13:20Z")

</div>

Well the dialect actually does, but with the refactoring mentioned above, it isn’t queried any longer …

---

<div class="post-metadata">

**Author:** ![beikov](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.hibernate.org/beikov/32/258_2.png) [@beikov](https://discourse.hibernate.org/u/beikov)\
**Post date:** [October 9, 2026, 8:33am UTC](https://discourse.hibernate.org/t/systimestamp-in-function/12447/4 "2026-10-09T08:33:45Z")

</div>

I checked the code and the `isKeyword` method should be called, which checks the dialect keywords, but maybe there is a bug.  
Please try to create a reproducer with our [test case template](https://github.com/hibernate/hibernate-test-case-templates/blob/master/orm/hibernate-orm-7/src/test/java/org/hibernate/bugs/JPAUnitTestCase.java) and if you are able to reproduce the issue, create a bug ticket in our [issue tracker](https://hibernate.atlassian.net) and attach that reproducer.
