Archives by Month: November 2008

Adventures in bad variable names

11/25/2008

There are many built-in, always-there variable scopes in CF, including #cgi#, #form#, #url#, etc., and one does well to avoid using these names for anything other than their intended purpose.  However, I was doing a CFHTTP call (in CF8) and set the result attribute to 'http' (the result attribute allows you to specify the return variable name rather than receive the 'cfhttp' default) and immediately had issues. 

I discovered, to my surprise, that 'http' is synonymous with 'cgi' - at least under CF8/IIS6.  I actually would have expected it to be synonymous with 'cfhttp' (I seem to recall that 'http' was the fixed return variable name from cfhttp calls in earlier versions of CF?).

Anyway, if I ever need cgi environment variable values I use, of course, #cgi#.  I don't ever recall using #http# and never suspected it existed.  Begs the question why synonymous scope names even exist.

Anyway, weird.


Posted by Kevin J. Miller in:ColdFusion

DBX 10.1.8 Released

11/18/2008

Minor  update in this version:

  • when launching the SQL*Exec window from the table or view detail page, the populated sql now has the columns [bracketed] (by request)
  • increased the default size of the textarea in the SQLExec window since although its actually sizable by way of resizing the frames, the frames are difficult to see/resize

Also, it seems that RIAForge still suffers from its frequent downtime, so I've added a new alternate download link for DBX on the Projects page.


Posted by Kevin J. Miller in:ColdFusionDBX

T-SQL function to get word count

11/18/2008

Similar in approach to the previous uf_charCount function, the following function returns the number of words in a string, assuming a space token as word separator.

Read more...


Posted by Kevin J. Miller in:SQL Server