Home
The Toolkit for Online Communities
17598 Community Members, 1 member online, 2453 visitors today
Log In Register
OpenACS Home : Forums : OpenACS Development : db_multirow and db_foreach -unclobber : One Message

Forum OpenACS Development: Re: db_multirow and db_foreach -unclobber

Collapse
Posted by Lars Pind on
The example I had is a page that lists logger entries. A logger entry is keyed to a user, a project, a variable, etc., through columns user_id, project_id, variable_id.

Then I want that page to be able to show me only rows with a certain user_id, project_id, and/or variable_id.

I also need to list the available project_id's, user_id's, and variable_id's, to let the user choose which ones to show.

Now, of course, when I iterate over the possible user_id's, unless I rename either the public page variable in ad_page_contract to something like 'selected_user_id', or rename the column on the fly using 'as row_user_id', which means that'll also be the name of that column in the multirow which we create, which I also find bad.

Bottom line: As things stand today, I have to find another name for my variable in one of two places (the page query or the template property), both of which are part of the page's "public API".

Hope that clarified things a bit.

/Lars