Re: Turning tables on their side

2005-10-19 Thread Jeffrey Goldberg
[posted only] On Oct 19, 2005, at 3:48 PM, sheeri kritzer wrote: One particular bit of SQL you may find helpful is this: concat(ifnull(a_id,""),ifnull(a_text,"")) concat with anything and a null value will produce a null value. That snippet of sql code will help you get one answer from the 2

Re: Turning tables on their side

2005-10-19 Thread Jeffrey Goldberg
[posted only] On Oct 19, 2005, at 4:07 PM, Jon Frisby wrote: Create an Excel spreadsheet. Import the raw data, structured as-is, into a worksheet. Select all the relevant columns. Go to Data -> "Pivot Table and Pivot Chart Report". Click "Finish". From the "PivotTable Field List", drag the

RE: Turning tables on their side

2005-10-19 Thread Jon Frisby
eled "Drop Row Fields Here", then drag question ID into the box labeled "Drop Column Fields Here". Voila. -JF > -Original Message- > From: Jeffrey Goldberg [mailto:[EMAIL PROTECTED] > Sent: Wednesday, October 19, 2005 1:44 PM > To: Brent Baisley > C

RE: Turning tables on their side

2005-10-19 Thread Jon Frisby
You want a Pivot Table. Excel will do this nicely (assuming you have 65536 rows or less), but SQL does not provide a mechanism to do this. If you want a web based interface you can look at Jtable. (I *think* that's what it's called -- it's a Java web app that provides an HTML pivot table interfac

Re: Turning tables on their side

2005-10-19 Thread sheeri kritzer
I agree with Brent. One particular bit of SQL you may find helpful is this: concat(ifnull(a_id,""),ifnull(a_text,"")) concat with anything and a null value will produce a null value. That snippet of sql code will help you get one answer from the 2 the original database had. Unless there's ever

Re: Turning tables on their side

2005-10-19 Thread Jeffrey Goldberg
[mailed and posted] On Oct 19, 2005, at 3:34 PM, Brent Baisley wrote: The person you inherited from formatted the data correctly in my opinion. I agree. What you are trying to do is store the data as you see it, which is rarely a normalized data model. Your presentation layer should han

Re: Turning tables on their side

2005-10-19 Thread Brent Baisley
The person you inherited from formatted the data correctly in my opinion. With the existing format, you can index all the data with a minimum number of indexes and quickly compile results. It can scale to any number of questions without having to modify the underlying data structure. It can