And if I could ask (this is a RBase sql I think), what advantage would there be in opting to avoid using a index? I always assumed if it is indexed then RBase would use the index and if not, well it wouldn't. But would there be a reason to avoid the index?
And is there a hierarchy that comes to play in the following: WHERE (irid = .virid) Where maybe irid = .virid ? Using the common math logic of "()" are evaluated first. Although it does not apply here, just curious for future reference. Sincerely, Paul Dewey From: [email protected] [mailto:[email protected]] On Behalf Of Bill Downall Sent: Wednesday, February 10, 2010 6:02 PM To: RBASE-L Mailing List Subject: [RBASE-L] - Re: I/O error redux Jennifer, WHERE (irid = .virid) will use an index, if the R:BASE optimizer determines that irid is the best indexed column to use. However, WHERE irid = (.virid) will not use an index ever, because it looks like an "expression" rather than a value. Bill On Wed, Feb 10, 2010 at 5:50 PM, <[email protected]> wrote: Jennifer: Looking briefly at your code, I see a couple things that I wouldn't do, not that either of these are show-stoppers as far as I'm concerned. SELECT (LISTOF(infotype)) INTO vvaluelist FROM inforesource WHERE (irid=.virid) Someone correct me if I'm wrong, but by putting "irid=.virid" in parenthesis, you are telling RBase to not use indexes. So if you're saying this part of the code is slow, try removing the parenthesis if the column irid is indexed. INSERT INTO tselecttype description VALUES .vvalue Is "description" a column? It should be in parenthesis. Karen

