On 17 Jan 2003 at 11:28, Steve Peacocke wrote: > > OK. I guess that's what I was asking. > > Yep, my guess is what Twenty Queries was doing was running the first. > It simply opens the query with what you have given it so nothing > special runs in the background there. Steve I had actually copied each part of the 2 part query into separate Q numbers. It seems that the temp table created in one Q is available to another? > > > So...Can I do > > > > SELECT (blah, blah) into MEMORY t1 > > > > followed by > > > > SELECT (blah, blah) > > JOIN MEMORY t1 on d.LogCode = t1.LogCode > > No - take a look at UNION. This will be able to do what you are after. > Then both queries will be run in the same go but produce a result that > combines the results. It was a bit hard to read my SQL (the mail program stripped out the <CR>s). What I was trying to do was to read a group total of a super- group so that I could then show the percentage of each sub-group in that super-group. (there is probably a better way).
What I have suggested above achieves that just fine. > > > Do I have to tidy up the Memory table when I've finished? and how? > > You won't have to use a memory table then, but if you do, simply > closing the query will clean up the memory table. Thanks for clearing that up for me. I guess you're right into lesson plans for 2003? Mark > > Steve Peacocke > Lecturer, NZ Diploma in Business > Lecturer, Batchelor of Computing Systems > Waiariki Institute of Technology > > > > ---------------------------------------------------------------------- > ----- > New Zealand Delphi Users group - Delphi List - > [EMAIL PROTECTED] > Website: http://www.delphi.org.nz > To UnSub, send email to: [EMAIL PROTECTED] > with body of "unsubscribe delphi" > Web Archive at: http://www.mail-archive.com/delphi%40delphi.org.nz/ > --------------------------------------------------------------------------- New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED] Website: http://www.delphi.org.nz To UnSub, send email to: [EMAIL PROTECTED] with body of "unsubscribe delphi" Web Archive at: http://www.mail-archive.com/delphi%40delphi.org.nz/
