-1

I'm trying to setup spamassassin per user config files via MySQL, and I get this error:

Sep  8 12:09:13.668 [12307] warn: config: failed to parse line, skipping, in "/etc/mail/spamassassin/local.cf": user_scores_custom_query SELECT preference, value FROM _TABLE_ WHERE username = _USERNAME_ OR username = '$GLOBAL' OR username = CONCAT('%',_DOMAIN_) ORDER BY username ASC

But I can't see wat is wrong with this config line, can someone help me?

EDIT: here is all of local.cf.

required_hits 5.0
report_safe 0
required_score 5
rewrite_header Subject [SPAM]

user_scores_dsn DBI:mysql:spamassassin:localhost:3306
user_scores_sql_password db_username
user_scores_sql_username db_pass
user_scores_custom_query SELECT preference, value FROM _TABLE_ WHERE username = _USERNAME_ OR username = '$GLOBAL' OR username = CONCAT('%',_DOMAIN_) ORDER BY username ASC
Nemke
  • 248
  • 5
  • 9
  • Without knowing your /etc/mail/spamassassin/local.cf nobody can help you. Does your query run within mysql without errors? – deagh Sep 08 '13 at 12:18
  • If you take look at error you can see config line that is problematic. Yes I tried to and it worked in mysql. If you need all of local.cf lines I will paste it. – Nemke Sep 08 '13 at 12:26

1 Answers1

0

From a quick look at the docs I deduce this is called user_scores_sql_custom_query and not user_scores_custom_query.

Marki
  • 2,795
  • 3
  • 27
  • 45