[Zope] ZSQL Method problem

McDonnell, Larry lmcdonnell@protonenergy.com
Tue, 16 Jul 2002 10:27:44 -0400


I have come across a strange problem in ZSQL Method.  I am using OBDC
adapter to MS Access. Below is real information.


select * from part_number
where (part_num like <dtml-sqlvar part_num type="string">) and
      (title_description like <dtml-sqlvar title_description type="string">)
      (category_type like <dtml-sqlvar category_type type="string">);
To test this query, I input the following:

Part_num 66%
title_description %
category_type %

My results:
There was no data matching this Type Part Number Search query. 
select * from part_number where (part_num like '66%') and (title_description
like '%') and (category_type like '%'); 
If I remove the variable category_type I will see records displayed with a
part_num starting with "66". If I add it back I get no results.

All the variables has information stored in the db. I have used other ZSQL
methods with as many 4 parameters and they work. I thought maybe there were
some reserved words and changed it to document_type but the same results.
Any clues? 

Larry McDonnell

Proton Energy Systems
50 Inwood Rd.
Rocky Hill, CT 06067
(860) 571-6533 ext. 531