| From: | Madison Kelly <linux(at)alteeve(dot)com> |
|---|---|
| To: | Merlin Moncure <mmoncure(at)gmail(dot)com> |
| Cc: | pgsql-general(at)postgresql(dot)org |
| Subject: | Re: Select question |
| Date: | 2007-08-31 18:28:56 |
| Message-ID: | 46D85DE8.9080005@alteeve.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
Merlin Moncure wrote:
> I seem to recall giving out a query about that in the IRC channel a
> while back...so if you got it from me, now I'll attempt to finish the
> job :-).
>
> If you can get postfix to look at a view, maybe you could
> CREATE VIEW email_v AS
> SELECT
> usr_email, dom_name,
> b.dom_name||'/'||a.usr_email||'/inbox' AS email_file
> FROM users a, domains b
> WHERE
> a.usr_dom_id=b.dom_id;
> AND a.usr_email='mkelly'
> AND b.dom_name='test.com';
>
> and just
> select * from email_v where usr_email = 'mkelly' and dom_name = 'test.com';
>
> merlin
Hiya,
Nope, wasn't me, but I was indeed able to solve the problem with a few
(I posted the details in a follow up). It was pretty similar to your
suggestion, so you were certainly onto something. :)
Madi
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Tom Lane | 2007-08-31 18:37:01 | Re: ERROR: table row type and query-specified row type do not match |
| Previous Message | Merlin Moncure | 2007-08-31 17:51:23 | Re: auditing in postgresql |