CF Debug Copy for Internet Explorer

So I've been using my CF Debug Extension for SQL Explorer for a few months now. It works great when I just need to run a query to see the results. However, when I need to actually refine a query, which is quite often, I find that I usually end up copying the query from SQL Explorer to MS SQL Query Analyzer. This is because I have the excellent SQL Prompt plugin for Query Analyzer which makes looking up tables and columns a snap. (SQL Explorer is supposed to have code assistance but I haven't been able to get this to work.) I've found myself doing this double copy and paste more and more over the past few weeks so I decided to put something together that would let me skip the SQL Explorer step entirely. Introducing CF Debug Copy for Internet Explorer.

First run the Windows Installer, CopyCFDebug.msi, which you can download using the download link at the bottom of this post. (You may need to right click and "Save link as...".) Next restart IE then copy a ColdFusion query, queryparams and all, from the debug output using the new Copy ColdFusion Query context menu item.

Then just paste the query into SQL Query Analyzer or any other tool for that matter and you are all set.

Note that this may not work on all queries. If by chance you are using CF Debug Copy with data manipulation queries I would definitely suggest checking the pasted output before executing the query. Also, I've only tested this on IE 6 in Windows XP SP 2. I'd be very interested to hear if it works in IE 7 on Windows XP or Vista so if you try it on one of these platforms please let me know how you make out.

If you are curious how I did this just take a look at Adding Entries to the Standard Context Menu on Microsoft's MSDN site. You can also find the source in the [Program Files]\CF Debug Copy for Internet Explorer\cfdebugcopy.html.

You may also be wondering why I didn't make a FireFox extension as this is my browser of choice. Well there are two reasons. First, the application I'm working on is IE only. (Sad I know.) Second, FireFox extensions are a little more complicated to create. That being said, look for a FireFox extension with the same functionality very soon.

Related Blog Entries

Jason's Gravatar I just installed on IE 7 on XP, seems to work just fine. Thanks for the work on this plug in, it is going to no doubt be a time saver.
# Posted By Jason | 3/9/07 8:07 AM
Nathan Mische's Gravatar Glad to hear it is working in IE7.
# Posted By Nathan Mische | 3/9/07 8:26 AM
Dmitriy's Gravatar Hey, Nathan. This is Dmitriy from ex-FBHC. Very nice tool and very helpful. Do you it's possible to do the same for stored procedures? Shoot me an email whenever you get a chance.
# Posted By Dmitriy | 3/9/07 9:00 AM
BlogCFC was created by Raymond Camden. This blog is running version 5.8.001.