On Dec 28, 2013, at 2:01 PM, Scott Klarenbach wrote:

> I'm playing around with the idea of a sort of "Language Integrated Query" 
> like LINQ.  For example:
> 
> > (sql (query 'my-table
>      #:where (λ (row) (> (hash-ref row 'id) 3))))
> "select * from my-table where id > 3"
> 

I understand your motivation now. See Greg's suggestions. I think they are 
right on. 

> In another thread, I'd like to poll this list as to the benefits (if any) of 
> such a linq-style approach.  I got inspired by this paper: 
> http://homepages.inf.ed.ac.uk/slindley/papers/practical-theory-of-linq.pdf 
> and really enjoyed the c# linq stuff I've played around with.  It may very 
> well be; however, that this is not desired or useful,


(1) Part of the Racket philosophy is not to exclude some approach because it is 
not desired or not considered useful. We welcome experimentations such as yours 
and when things fail, we re-consider our language. (No promise that we change 
it :-) 
(2) I think a DSL approach to DBs based on syntactic abstractions might be more 
useful. 

Keep us posted. Better yet, report on your experience at the next RacketCon. 



> As an aside:
>  
> This might be a MIT misunderstanding about the relationship between Scheme 
> and the lambda calculus. It is certainly not possible in general and I see no 
> pragmatic use case for an approximation. 
> 
> It would be really nice to print the source code of a known procedure on the 
> repl, in order to get a quick view of what it does.  Or, the "pa" function 
> which prints out the arguments of a procedure is even more useful.


I think a function that displays (1) docs and/or (2) specs (say contracts) 
might be a lot more useful than raw source. 

-- Matthias



____________________
  Racket Users list:
  http://lists.racket-lang.org/users

Reply via email to