Re: Things that Longhorn seems to be doing right

Larry McVoy
2003-10-30T04:08:45Z

> SQL is a bloated pig; an effective
> file system needs to be both useful and efficient, leading me to think
> that we should consider a more succinct query mechanism for any
> metadata-based file system.

It's certainly possible to make a mostly/partially SQL compliant query
engine which is lean. We did so for the commercial version of BK, i.e.,
this does exactly what you think it does:

select ID,STATUS,SEVERITY,PRIORITY,SUMMARY
from bugs
where (SEVERITY == 1 or SEVERITY == 2 or SEVERITY == 3) and
(PRIORITY == 1 or PRIORITY == 2 or PRIORITY == 3) and
(STATUS == "new" or STATUS == "open" or STATUS == "assigned")
order by
ID

The code which implements that:

wc query.c select.y
284 830 5679 query.c
650 2033 13775 select.y
934 2863 19454 total

SQL compatibility isn't the problem, full (and bloated) SQL implementations are.
--
---
Larry McVoy lm at bitmover.com http://www.bitmover.com/lm