Further
I created two new Views to see if i could figure this out
===
View: oldids2
===
SELECT
ARRAY (
SELECT
array_to_string(
ARRAY [ 'To:' :: CHARACTER VARYING,
maildomains. NAME,
' ' :: CHARACTER VARYING,
(
CASE
WHEN (maildomains.spam_actions = 1) THEN
'deliver' :: TEXT
WHEN (maildomains.spam_actions = 3) THEN
'delete' :: TEXT
ELSE
NULL :: TEXT
END
) :: CHARACTER VARYING ], ' ' :: TEXT
) AS ruleset
FROM
maildomains
WHERE
(
(maildomains.status = TRUE)
AND (
maildomains.spam_actions <> 2
)
)
UNION ALL
SELECT
array_to_string(
ARRAY [ 'FromOrTo:' :: TEXT,
'default' :: TEXT,
'store' :: TEXT ], ' ' :: TEXT
) AS array_to_string
) AS ID;
===
Which outputs
id
{"To: domain1 deliver","To: domain2 deliver","FromOrTo: default store"}
=================
AND
=================
===
View: oldtable2
===
SELECT
array_to_string(
ARRAY [ 'To: ' :: CHARACTER VARYING,
maildomains. NAME,
' ' :: CHARACTER VARYING,
(
CASE
WHEN (maildomains.spam_actions = 1) THEN
'deliver' :: TEXT
WHEN (maildomains.spam_actions = 3) THEN
'delete' :: TEXT
ELSE
NULL :: TEXT
END
) :: CHARACTER VARYING ], ' ' :: TEXT
) AS ruleset
FROM
maildomains
WHERE
(
(maildomains.status = TRUE)
AND (
maildomains.spam_actions <> 2
)
)
UNION ALL
SELECT
array_to_string(
ARRAY [ 'FromOrTo:' :: TEXT,
'default' :: TEXT,
'store' :: TEXT ], ' ' :: TEXT
) AS ruleset;
===
Which Outputs
ruleset
To: domain1 deliver
To: domain2 deliver
FromOrTo: default store
Not sure if this helps..... basically i was trying to break down the
spamactions veiw to take a look at how it worked
>From what i could see these two were CROSS JOIN together and then that
output CROSS JOIN with a generate_series section.
no clue if that helps....
Thanks for your help
--
View this message in context:
http://baruwa-users-list.963389.n3.nabble.com/Issues-with-low-spam-delivery-tp4027481p4027530.html
Sent from the Baruwa users list mailing list archive at Nabble.com.
_______________________________________________
http://pledgie.com/campaigns/12056