We help IT Professionals succeed at work.

Check out our new AWS podcast with Certified Expert, Phil Phillips! Listen to "How to Execute a Seamless AWS Migration" on EE or on your favorite podcast platform. Listen Now

x

CGGRID Mystery

hefterr
hefterr asked
on
Medium Priority
247 Views
Last Modified: 2012-05-11
Hi (again),
I have a CFGRID table that uses a remote cfc to populate it.  One of the columns I'd like to contain "Yes" or "No" (without the quotes).

No matter how I try, it display in the grid as "true" or "false" (without the quotes).  If I change the value to Yess or Noo it displays OK.

Has anyone heard of this or have a clue.  I dumped the query results and the QueryConvertForGrid results and everything looks good until the actual display?

Below is a section of code to give you the idea

Thanks again for your expertise,
hefterr

<cfloop query="getProds">
      <cfset queryaddrow(format)>
	    <cfset querysetcell(format,'Order',getProds.OrderId)>
        <cfset querysetcell(format,'ProdName',getProds.ProductName)>
        
        <cfif getProds.SubInd eq "true">
          <cfset YNsubInd = "Yes">
        <cfelse>
          <cfset YNsubInd = "No">  
        </cfif>
        
        <cfset querysetcell(format,'SubInd',YNsubInd)>
	    <cfset querysetcell(format,'Sdate',getProds.Sdate)>
	    <cfset querysetcell(format,'Edate',getProds.Edate)>

etc....
	    
        
        <cfset querysetcell(format,'QTY',getProds.QTY)>

Open in new window

Comment
Watch Question

Author

Commented:
FYI.  Ifound this link with the same problem :
http://stackoverflow.com/questions/884474/cfgrid-boolean-column-as-yes-no

I can't believe ut's this complicated!!!!!

hefterr
CERTIFIED EXPERT
Commented:
Unlock this solution and get a sample of our free trial.
(No credit card required)
UNLOCK SOLUTION

Author

Commented:
@gdemaria,
I like the space around the " Yes " / " No " as this will appear as per specs.  I don't have access now so I'll try in the morning.  But it sounds promising.

hefterr

Author

Commented:
added a space before and after the yes/no and it worked fine.  Thanks for the clever solution!

hefterr
Unlock the solution to this question.
Thanks for using Experts Exchange.

Please provide your email to receive a sample view!

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.