[Zope-DB] mySQL query question

Maszerowski, Thomas TMaszerowski@crt.xerox.com
Wed, 22 Jan 2003 17:07:26 -0500


  I'm using a mySQL database (that I did not set up). It's a list of items
each of which is owned by a name. Rather than have the name in the table as
a string, the owner is actually an index into another, separate table, that
contains the text string of the name. For adding records, I figured out how
to use a SQL method and then a <dtml-in> to build the HTML <select> so the
user doesn't see anything but the text. However, when I do a listing of the
database, I would like to also to display the text of the name, rather than
the index. How can I do this? I would essentially like to only call the SQL
method for the names once, and reference the text associated with the owner
index for each line in the listing. Any help, or pointers to information
would be most appreciated.


Tom Maszerowski
Xerox Innovation Group/Xerox Engineering Center
MS: 105-70C
Phone (585) 422-1579
Fax (585) 422-2837