agora inbox for pgsql-sql@postgresql.org  
help / color / mirror / Atom feed
From: Andreas Joseph Krogh <andreas@visena.com>
To: pgsql-sql@postgresql.org
Subject: Re: Effective query for listing flags in use by messages in a folder
Date: Wed, 18 Mar 2015 14:01:04 +0100 (CET)
Message-ID: <VisenaEmail.35.3a752eb0ccc59659.14c2cf6ffdf@tc7-visena> (raw)
In-Reply-To: <1426683287617.19714@metametrics.co.uk>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-sql>

På onsdag 18. mars 2015 kl. 13:54:50, skrev Hector Vass <
hector.vass@metametrics.co.uk <mailto:hector.vass@metametrics.co.uk>>: OK I get 
it ..

 

drop type if exists myflags cascade; create type myflags as 
enum('is_seen','is_replied','is_forwarded','is_deleted','is_draft','is_flagged');
drop table if exists message; create table message(     folder_id integer not 
NULL,     msg varchar(200),     is_flag myflags ); insert into message values 
(1,'msg b','is_seen'), (1,'msg c','is_seen'), (1,'msg d','is_seen'), (1,'msg 
d','is_replied'), (1,'msg e','is_seen'), (1,'msg e','is_replied'), (1,'msg 
h','is_deleted') ;   Not quite; you have 2 entries, one for each flag, for "msg 
d". I must haveone tuple per message in this table.   -- Andreas Joseph Krogh 
CTO / Partner - Visena AS Mobile: +47 909 56 963 andreas@visena.com 
<mailto:andreas@visena.com> www.visena.com <https://www.visena.com;  
<https://www.visena.com;  

view thread (12+ messages)  latest in thread

Message-ID: <VisenaEmail.35.3a752eb0ccc59659.14c2cf6ffdf@tc7-visena>
Permalink:  ../VisenaEmail.35.3a752eb0ccc59659.14c2cf6ffdf@tc7-visena/
Also on:    postgresql.org/message-id/VisenaEmail.35.3a752eb0ccc59659.14c2cf6ffdf@tc7-visena

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: andreas@visena.com
  Subject: Re: Effective query for listing flags in use by messages in a folder
  In-Reply-To: <VisenaEmail.35.3a752eb0ccc59659.14c2cf6ffdf@tc7-visena>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox