News for hackers. Stuff that matters.
Re:Sqlphobia: The Irrational Fear of SQL by bellybutton on Sunday April 04, 2010 @05:14PM (#1240831)
Common programming idioms, for example iteration, are hard to express in a SQL query, and I think if you try to force iterative ideas on this declarative language the result is frustration or fear.

The need to be able to express yourself iteratively was a motivator for Microsoft's DryadLINQ - a programming language for distributed computation that has SQL-like constructs integrated into C#, giving you a high-level language with some of the declarative benefits as well as some of the imperative benefits (including more natural ways to express iteration).

Re:Sqlphobia: The Irrational Fear of SQL by DrJokepu on Sunday April 04, 2010 @05:42PM (#1240869)
I think if you try to force iterative ideas on this declarative language the result is frustration or fear

But fortunately we have (tail) recursion to fight back in most declarative languages. Which is something that's completely missing from SQL. There should be a way to express recursion in SQL queries in my opinion.

Re:Sqlphobia: The Irrational Fear of SQL by jamii on Sunday April 04, 2010 @09:34PM (#1241154)
Datalog is more or less equivalent to SQL with recursion. I don't know of any serious, database-backed implementations but there are a lot of in-memory implementations and some interesting extensions for distributed databases.

http://en.wikipedia.org/wiki/Datalog

Re:Sqlphobia: The Irrational Fear of SQL by yangyang on Sunday April 04, 2010 @06:49PM (#1240949)