Re: Pet Peeves? - Mailing list pgsql-general

From Shane Ambler
Subject Re: Pet Peeves?
Date
Msg-id 49846593.3000304@Sheeky.Biz
Whole thread Raw
In response to Re: Pet Peeves?  (Gregory Stark <stark@enterprisedb.com>)
List pgsql-general
Gregory Stark wrote:

>> MS-Access SQL has a TRANSFORM clause that allows for crosstab queries without
>> the need to know in advance the number of columns:
>> http://msdn.microsoft.com/en-us/library/bb208956.aspx
>
> That's puzzling. I wonder what they do about clients requesting info about the
> results. Or for that matter such queries being used in subqueries or anywhere
> else where the surrounding code needs to know the type of results to expect.
>

Well as subqueries you would expect an error.

Not sure with access but I know that with RealBasic you can handle the
variations. This allows you to build an "access style" front end that
isn't fixed to one db structure.

dim rs as recordset

rs = db.sqlquery("select...")

for x = 1 to rs.fieldcount
  if vartype(rs.idxfield(x).value) = kTypeDate then
  ...
  ...
next

you could also use rs.idxfield(x).stringvalue and parse it yourself




--

Shane Ambler
pgSQL (at) Sheeky (dot) Biz

Get Sheeky @ http://Sheeky.Biz

pgsql-general by date:

Previous
From: Martijn van Oosterhout
Date:
Subject: Re: Pet Peeves?
Next
From: "Holger Hoffstaette"
Date:
Subject: Re: Pet Peeves?