That's not a naive question at all. I'll try and answer it. Creating an index on MY_FIELD will probably speed things up. It depends on the cardinality of the data and how many null values there are. For example, if this is a large file, say 10,000,000 records, and MY_FIELD contains something like a state code (MA, CT, CA, etc), your results will be better, but not by much. There are only 50 possible values*, so the index nodes will be rather large. If MY_FIELD contains something like a zip code, where there are thousands of possible values, the index nodes will be much smaller and your select statements should work faster. I don't understand all the internals, but from my experience, I have found that Unidata/Universe handle indexes with low cardinality better than other databases.
For your specific question about nulls, it depends on how many nulls you expect to find. Using the above examples, if you only expect a handful of null values, your select statement "should" work the same in either case and it will be much faster with an index. Did that help? * Please forgive my usage of a possibly politically incorrect and USA-oriented example. Best I could think of on the spur of the moment and no disrespect of great countries like Australia, New Zealand, Puerto Rico, etc, was intended. Charlie Rubeor Unix/Database Admin The Wiremold Company 800.338.1315 x3498 860.523.3690 fax [EMAIL PROTECTED] wrote on 06/06/2005 08:58:28 PM: > I've got a naive Unidata question, but figured I'd throw it out there > anyway. In short, does indexing a field in a given file help performance > when querying for an empty string? ie: > > SELECT MY_TABLE WITH MY_FIELD='' > > I've always assumed yes but would like to hear other's thoughts. > > > Jeff Butera, Ph.D. > Administrative Systems > Hampshire College > [EMAIL PROTECTED] > 413-559-5556 > > "...our behavior matters more than the beliefs that we profess." > Elizabeth Deutsch Earle > ------- > u2-users mailing list > [email protected] > To unsubscribe please visit http://listserver.u2ug.org/ ------- u2-users mailing list [email protected] To unsubscribe please visit http://listserver.u2ug.org/
