httpd-modules-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nick Kew <>
Subject Re: APR DBD: Column names from query
Date Fri, 29 Aug 2008 19:13:10 GMT
Dave Ingram wrote:

> First off, if this isn't the correct place to ask this then I apologise,
> but it seemed the most appropriate list. If there's somewhere more
> appropriate, please let me know.
> I've had a quick look for some information on accessing a database via
> APR, and after glancing through the header files, I still have a
> question: is it possible to get the column names from the query results?

Yes, with sufficiently up-to-date versions of apr_dbd and mod_dbd.
Hints about how it works can be found in the relevant CHANGES files.

Sorry to be terse, but it would take too long to dig up URLs
from here.

> <SQLRepeat "SELECT baz, bar, qux FROM sometable WHERE baz='foo'">
> <VirtualHost *:80>
>   DocumentRoot /www/root/path/$baz
>   ServerName $bar
>   ServerAdmin $qux
> </VirtualHost>
> </SQLRepeat>

Interesting idea.  Are you familiar with mod_vhost_dbd, and even
mod_macro, which do somewhat-related things?

Nick Kew

View raw message