I tried all of the code suggestions and it was still giving incorrect results. After looking further I realized that I was missing #address2# after the cfif cfif>#address2#</cfif> After including that I tested the code and each one of the suggestions worked. Thanks for everyone's help...
I am displaying a query with fields address1 and address2. I only want address2 to display if there is data in the database. The problem is my <cfif #trim(address2)# NEQ ""><br></cfif> isn't catching everything. When I look in the database their is nothing in the field. Less than 1% of the...
Kevin, what does the error below mean that I received. In my case what would the two parameters had been?
Cathy
You have attempted to dereference a scalar variable of type class java.lang.String as a structure with members.
The error occurred in...
Thanks everyone for all of the help, I tried a couple of different scenerios and here are the results. I replaced the <cfset sqlStr = sqlStr + "AND ... to <cfset sqlStr = sqlStr & "AND ... and that resolved the issue with the error I was receiving (The value "WHERE 1=1" cannot be converted to a...
This is my first time trying to code something like this, did I do this correctly? I got the error below. Also, where should I be using a IF statement to find out if one of the fields were filled out or not so that it will know to bypass the queries?
The value "WHERE 1=1" cannot be converted to...
Thanks DonHawaii, that worked great. Below is how I expanded on the other parameters, I found myself trying to cover every possible way that the user may try to search on. I tested the screens and it seems to work, I'm not sure if I could have coded it an easier way though. What I have...
search screen query logic CFIF
I am building a search screen and the search items are
COUNTY, CITY, ZIP, NAME. I would like to be able to
search on each item independent of the other and I
would like to be able to search on the COUNTY and CITY
using AND.
I have two select boxes populated by the...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.