chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] postgresql tests/run.scm line 17 ff.


From: Herr
Subject: Re: [Chicken-users] postgresql tests/run.scm line 17 ff.
Date: Sun, 03 Mar 2013 17:50:30 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130215 Thunderbird/17.0.3

Am 03.03.2013 16:12, schrieb Peter Bex:
> On Sun, Mar 03, 2013 at 04:03:29PM +0100, Herr wrote:

>> My pleasure. I am not through checking it all yet ;-)
> 
> :)
> 
>> I have been using postgresql a lot in Tcl and PHP, but scheme is new to me.
> 
> I hope you find this more convenient than the shitty functions provided
> by PHP.  I always get frustrated having to write code for handling
> booleans and arrays in PHP all the time, over and over again.
> How is TCL's interface?

PHP: with PDO I don't find it so shitty. A lot of query results it get as array 
of
objects, ready to handle to the presentation/HTML layer, because the code goes 
with
the data.

Tcl: it is extremely succinct, getting the result as flat list covers all the 
uses
where the select column list does not change. With some small helpers a typical
pattern is:

foreach {fname lname email} [pg_query_list "select fname, lname..."] {
     # variables are bound to the row values, go ahead
}

/Str.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]