[Zope] Re: Howto debug (Re: PostgreSQL Problem)
Siggy Brentrup
bsb@winnegan.de
21 Mar 2001 16:58:51 +0100
Andreas Tille <tillea@rki.de> writes:
> On Wed, 21 Mar 2001, Steve Spicklemire wrote:
>
> > you might also try just:
> >
> > <dtml-var MenuItem>
<dtml-var menuitem>
> Thanks for your hints. I tried both (i.Menuitem, MenuItem and also
> i.MenuItem). The usage of
> <dtml-var Menuitem>
> seemed me the best because this is the exact spelling when I use
> the database connection query test. The column was just named Menuitem
> regardingless the fact that it is spelled MenuItem in the SQL statement
> (OK, column names in PostgreSQL are case insensitive - why should they
> be in Zope??). Moreover there was no table prefix in the test-output.
Enter the exact query in psql and you'll see PostgreSQL's idea of
column names. They are lowercase only unless enclosed in double quotes
as in
select count(*) as "Anzahl" ...
> I wonder if there is an internal object which contains all valid
> column names I could query.
AFAIK, you can't get at it from DTML.
> One more idea: If I test the query I have to go through an extra screen
> where I have to commit that "This query requires no input." Could this
> cause any problem?
No, this is the parameter entry screen, with a parameterless query
it requires no input.
Use lower-case only
Siggy
--
Siggy Brentrup - bsb@winnegan.de - http://www.winnegan.de/
****** ceterum censeo javascriptum esse restrictam *******