RE: Need help with a SQL query

2000-06-22 Thread Philip Arnold - ASP
> Alternatively, what if I delete a category. Again, I'd have to > retrieve every item, iterate through each list, delete any > entries for that category, then save that item. Actually, if you don't re-use the numbers, you could leave the redundant numbers in the denormalised list, as it could ne

RE: Need help with a SQL query

2000-06-21 Thread Dave Watts
> If all you want is a comma seperated list of the categories > for each item. Why not just add a "categories" field to the > item table? Store the comma seperated list there. Because that would be denormalization of the data, which in a transaction processing system is VERY VERY BAD. That's why

Re: Need help with a SQL query

2000-06-21 Thread KChapman
<[EMAIL PROTECTED]> Subject: Re:

RE: Need help with a SQL query

2000-06-21 Thread Philip Arnold - ASP
> > Right, I'm not gonna address the whole thing (no time at the > moment), but > a > > quick word about sub-queries > > > > They should be used in 2 ways - one to return a single result; > > select * from myTable where myValue=(select myValue from myOtherTable > > where...) > > > > Or to return m

Re: Need help with a SQL query

2000-06-21 Thread Deanna L. Schneider
Doh, I forgot to add all the where clauses in that last sql thing, but you get the idea where t1.itemid = t2.itemid andt1.itemid = 1 Deanna Schneider Interactive Media Developer UWEX Cooperative Extension Electronic Publishing Gro

Re: Need help with a SQL query

2000-06-21 Thread Deanna L. Schneider
Couldn't you accomplish this with a group function? i.e. #name# - #description# #categoryid# I obviously can't test this, and I'm not sure this is exactly what you want, but have you tried something like this? d Deanna Sch

Re: Need help with a SQL query

2000-06-21 Thread Justin v0.9 MacCarthy
MAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, June 21, 2000 12:11 AM Subject: Need help with a SQL query > Sorry about the non-descriptive subject, but I'm tired and really couldn't > think of a way to describe my question in one line . > > I have a dat

Re: Need help with a SQL query

2000-06-21 Thread Seth Petry-Johnson
> Right, I'm not gonna address the whole thing (no time at the moment), but a > quick word about sub-queries > > They should be used in 2 ways - one to return a single result; > select * from myTable where myValue=(select myValue from myOtherTable > where...) > > Or to return multiple values > sel

RE: Need help with a SQL query

2000-06-21 Thread Philip Arnold - ASP
> Sorry about the non-descriptive subject, but I'm tired and really couldn't > think of a way to describe my question in one line . > > I have a database table of product information and a database table of > product category information. Each product may exist in more than one > category, so I c

Need help with a SQL query

2000-06-20 Thread Seth Petry-Johnson
Sorry about the non-descriptive subject, but I'm tired and really couldn't think of a way to describe my question in one line . I have a database table of product information and a database table of product category information. Each product may exist in more than one category, so I created a "m