1
votes

I recently had my computer main HDD fail and had to re-install everything from scratch. I was running cf10 (developer's edition) but could not find how to download it again so I ended up downloading and installing cf11. Installation was much easier than when I installed the cf10. However, at first, all my sites were not working. After much time spent, I tracked down a few things.

Many of my sql queries ended with a semicolon, select * from mydb where 1=1;. These all had to be removed for my queries to run in cf11.

Then I moved on to something else that was not working and found that cfif myquery.recordCount was not working. Again, after much time.. I eventually figured out that "it" is now case sensitive. I don't know what "it" is yet, but I replaced all (and that was quite a bunch!) of the .recordCount and .RecordCount to myquery.recordcount and this seems to please cf11 server.

Now, I did not find any of these bugs in the cf11 changes reported or commented anywhere and I'm still running into parts of my sites that are not working as they were running in cf10. In particular, right now I jammed on a login screen of a cart admin area. The db (now, after the changes above) finds the user, but it keeps bringing me back to the login page and does not properly process the redirecting part of the code.

I did find a web page that reference deprecated codes, but did not find any mention, anywhere, of the above "cf10 to cf11 upgrade" bugs.

My question is this, is anybody aware of a "update your code for cf11" guide or something that will help me do this without spending so much time on tracking all these down on my own?

Thank you

1
My question still stands, but I wanted to give an update on the login page bug. In the cf admin, under server settings - Memory variables, I had to check the "Use J2EE session variables". I don't remember having to do this in cf10 but the login page is now working. - user3552801
I have also gone from CF10 to CF11 and not so many problems. However I always type it as Query.RecordCount so probably was doing it the way CF11 likes it. The only problem I came across was that CF11 cannot handle the geography datatype from SQL Server whereas CF10 didn't have a problem with it. - volume one
I didn't think that myQuery.recordCount would be case sensitive. CF is mostly case sensitive and it can bite you when you serialize data to/from languages that are case sensitive (JavaScript, etc.). - Scott Jibben
Although you don't specify what database you are using, semi-colons are valid in cfquery tags. I use them all the time to execute multiple queries in the same cfquery tag. What you may be running into (if you are running mySQL). There is a security feature of mySQL that blocks multiple queries in the same transaction (cfquery tag). This article is a good starting point for allowing multiple queries in mySQL: bennadel.com/blog/… - Scott Jibben

1 Answers

0
votes

For finding deprecated code in specific files/folder, go to ColdFusion Administrator -> Debugging & Logging -> Code Analyzer and select the path/folder, select version as CF10 and click on 'Run Analyzer' button. It will list all the files with info/error for all the depricated tag/attribute your code is using. Good Luck.