Re: [GENERAL] Need schema design advice

2008-10-30 Thread Lew
Martin Gainty wrote: could you provide a brief explanation of EAV ? Please avoid HTML and eschew top-posting. The post from Jeff Soules in this thread included the advice: See e.g. http://en.wikipedia.org/wiki/Entity-Attribute-Value_model which points to an explanation. -- Lew -- Sent vi

Re: [GENERAL] Need schema design advice

2008-10-12 Thread Rodrigo E. De León Plicet
On Sun, Oct 12, 2008 at 8:10 PM, Ben Chobot <[EMAIL PROTECTED]> wrote: > On Oct 12, 2008, at 5:51 PM, Martin Gainty wrote: > > could you provide a brief explanation of EAV ? > > (...) in an EAV model you would do something like: > create table eav > ( > kind text primary key, > attr text, > value t

Re: [GENERAL] Need schema design advice

2008-10-12 Thread Ben Chobot
On Oct 12, 2008, at 5:51 PM, Martin Gainty wrote: could you provide a brief explanation of EAV ? Instead of: create table vehicles ( kind text primary key, wheels int ); insert into vehicles (kind, wheels) values ('car',4); insert into vehicles (kind, wheels) values ('bike',2

Re: [GENERAL] Need schema design advice

2008-10-12 Thread Martin Gainty
not endorse distribution to any party other than intended recipient. Sender does not necessarily endorse content contained within this transmission. > Date: Sun, 12 Oct 2008 20:22:14 +0100 > From: [EMAIL PROTECTED] > To: pgsql-general@postgresql.org > Subject: Re: [GENERAL] Need s

Re: [GENERAL] Need schema design advice

2008-10-12 Thread Sam Mason
On Sun, Oct 12, 2008 at 08:12:40PM +0100, I wrote: > As always, it's a trade off between what you're optimizing for. If > you're adding more preference types then go for a EAV style design, if > you're going to want to add more details about the preferences (this > does seem to be the common case,

Re: [GENERAL] Need schema design advice

2008-10-12 Thread Sam Mason
On Sat, Oct 11, 2008 at 05:10:26PM +, Matthew Wilson wrote: > I need to track employees and their preferred locations, shifts, and > stations. As always there's a trade off between "general" EAV style designs and more specific ones (as noted by Jeff). One, more EAV style, design that sprung t

Re: [GENERAL] Need schema design advice

2008-10-12 Thread Martin Gainty
[GENERAL] Need schema design advice > Date: Sun, 12 Oct 2008 13:55:42 + > > Jeff, this is *exactly* the kind of feedback I was hoping to get. > Thanks so much for the link and the explanation. > > Matt > > > -- > Sent via pgsql-general mailing list (pgsql-gener

Re: [GENERAL] Need schema design advice

2008-10-12 Thread Matthew Wilson
Jeff, this is *exactly* the kind of feedback I was hoping to get. Thanks so much for the link and the explanation. Matt -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Need schema design advice

2008-10-11 Thread Jeff Soules
On Sat, Oct 11, 2008 at 1:10 PM, Matthew Wilson <[EMAIL PROTECTED]> wrote: > I need to track employees and their preferred locations, shifts, and > stations. > > For example, I need to track that Alice prefers to work the morning > shift at the west-side location, and she likes to work the cash-reg

Re: [GENERAL] Need schema design advice

2008-10-11 Thread Artacus
I need to track employees and their preferred locations, shifts, and stations. For example, I need to track that Alice prefers to work the morning shift at the west-side location, and she likes to work the cash-register station. Also, I need to track that Bob likes the west-side and north-side l

[GENERAL] Need schema design advice

2008-10-11 Thread Matthew Wilson
I need to track employees and their preferred locations, shifts, and stations. For example, I need to track that Alice prefers to work the morning shift at the west-side location, and she likes to work the cash-register station. Also, I need to track that Bob likes the west-side and north-side lo