Debugging Dynamic Database Queries
Before we finish this chapter, there is something you should be aware of. Look at the following code:
Chapter 3, "Accessing the ColdFusion Administrator," I mentioned the debugging screens (and told you that we'd use them in this chapter). The debugging screens can be used to append debug output to the bottom of generated pages, as seen in Figure 10.19.
<!--- Get a movie from database --->
<cfquery name="movie" datasource="ows">
SELECT FilmID, MovieTitle,
PitchText, Summary,
DateInTheaters, AmountBudgeted
FROM Films
WHERE FilmID=#URL.FilmID#
</cfquery>
Figure 10.19. Dynamic SQL specific are displayed along with the standard ColdFusion debugging output.
Chapter 3 for instructions on turning on debug output. Once enabled, execute any page in your browser and the debug output will be appended automatically.