[GH-ISSUE #977] SQLite: SQL prepare failed: no such function: now? #826

Closed
opened 2026-02-27 11:13:46 +03:00 by kerem · 2 comments
Owner

Originally created by @ghost on GitHub (Nov 27, 2016).
Original GitHub issue: https://github.com/modoboa/modoboa/issues/977

Hi,

I tried to experiment SQLite as db, but I got this error from Postfix:

Nov 25 19:32:20 domain postfix/cleanup[27161]: fatal: dict_sqlite_lookup: /etc/postfix/modoboa/sql-aliases.cf: SQL prepare failed: no such function: now?

The WebUI and dovecot is functioning properly. I'm using the latest (1.6.1) version.

Originally created by @ghost on GitHub (Nov 27, 2016). Original GitHub issue: https://github.com/modoboa/modoboa/issues/977 Hi, I tried to experiment SQLite as db, but I got this error from Postfix: ``` Nov 25 19:32:20 domain postfix/cleanup[27161]: fatal: dict_sqlite_lookup: /etc/postfix/modoboa/sql-aliases.cf: SQL prepare failed: no such function: now? ``` The WebUI and dovecot is functioning properly. I'm using the latest (1.6.1) version.
kerem 2026-02-27 11:13:46 +03:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@tonioo commented on GitHub (Nov 27, 2016):

Looks like SQLite does not provide the now() function. Can you try to replace now() by datetime('now') in /etc/postfix/modoboa/sql-aliases.cf please?

<!-- gh-comment-id:263118961 --> @tonioo commented on GitHub (Nov 27, 2016): Looks like SQLite does not provide the `now()` function. Can you try to replace `now()` by `datetime('now')` in /etc/postfix/modoboa/sql-aliases.cf please?
Author
Owner

@ghost commented on GitHub (Nov 27, 2016):

Replaced, and it's working now! Thank you for the fast response.

Cheers! ;)

<!-- gh-comment-id:263122433 --> @ghost commented on GitHub (Nov 27, 2016): Replaced, and it's working now! Thank you for the fast response. Cheers! ;)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/modoboa-modoboa#826
No description provided.