Skip to main content
Inspiring
July 19, 2010
Question

CFGRID Binding Not Working in CF9

  • July 19, 2010
  • 1 reply
  • 1072 views

I'm having trouble with a CFGRID that works fine in CF8, but when trying to run it on CF9 I get no results and it's like the grid is loading forever. I did have to remove the cfajaximport I was using to get it to load at all, which is does now with the columns and the rest of the grid, but no rows. It's bound to a CFC and I know it works - this is happening to ALL my grids in CF9 now.

Here's what I've checked:

- CFIDE folder is mapped

- CFC is loaded

- firebug shows a ton of CSS errors from ext-all.css, but the GET request comes back with: {"QUERY":{"COLUMNS":["ID","PAGE","PAGETITLE","SECTION","EDITLINK"],"DATA":[[75,"\/about\/index.cfm","About the Corporation","About",,"TOTALROWCOUNT":7}

No rows in the grid though. 

Grid Code:

                    <cfgrid name="contentGrid" format="html" pagesize="25" selectmode="row" striperowcolor="F0F0F0" striperows="yes" selectcolor="##666666"

                        bind="cfc:assets.cfc.common.getPagesGrid({cfgridpage},{cfgridpagesize},{cfgridsortcolumn},{cfgridsortdirection})">

                        <cfgridcolumn name="ID" header="ID" width="50">

                        <cfgridcolumn name="section" header="Section" width="300">

                        <cfgridcolumn name="pageTitle" header="Page Title" width="300">

                        <cfgridcolumn name="editLink" header="" width="50">

                        </cfgrid>

Thanks for any help you can provide!

This topic has been closed for replies.

1 reply

Participant
October 13, 2010

Hi Pete,

Have you fixed this cfgrid problem? I have the similar issue. Note: if I select any one of the grid column then the dataset appears.

Pete_L_Author
Inspiring
October 13, 2010

Yeah, I finally dumped the SQL value of the query that was being run in the bind and realized that the CF9 MySQL driver hates it when you try to CONCAT a text value and a numeric value, so the query wasn't working.  Using CAST in the query solved the query and then the grid started working again.