Re: SQL queries as sets: was The tragedy of SQL

2021-09-15 Thread Raymond Brinzer
On Wed, Sep 15, 2021 at 12:55 AM Steve Litt wrote: > Rich, could you please elaborate on SQL queries being based on sets? I > never thought of it that way, and would like to hear your related > thoughts. I'll take a crack at this. Going through the setup will require a little patience, but I thi

Re: SQL queries as sets: was The tragedy of SQL

2021-09-15 Thread Rich Shepard
On Wed, 15 Sep 2021, Steve Litt wrote: Rich, could you please elaborate on SQL queries being based on sets? I never thought of it that way, and would like to hear your related thoughts. SteveT, In the 1980s, when there were computer magazines such as Byte and Database Administrator (among man

Re: SQL queries as sets: was The tragedy of SQL

2021-09-15 Thread rob stone
> > Rich, could you please elaborate on SQL queries being based on sets? > I > never thought of it that way, and would like to hear your related > thoughts. > When Codd & Date elaborated the relational model, it was based on set theory. You have sets of data. Is there a relationship between the

Re: SQL queries as sets: was The tragedy of SQL

2021-09-15 Thread Brent Wood
I agree. I've always thought SQL was a great example of set theory put into practice. You specify the elements (select items) and conditions (where clause) to return the (sub)sets you want. Spatial data is also about sets - a polygon is theoretically defined as the set of points contained by a

Re: SQL queries as sets: was The tragedy of SQL

2021-09-14 Thread Guyren Howe
Oh, yeah, wow. Big topic. My original post in the series is in significant part about how SQL hides this sort of thing from you. A table is a set:  a set of true facts, all having the same structure, so you can operate on all of them with any operation on the individual rows. Multiple tables,