SQL Builder
A useful built-in feature of ColdFusion Studio is the SQL Builder which allows you to view the table layouts and make queries on the fly.
To do this click on Tools > SQL Builder
FIGURE 114 ColdFusion's built-in SQL builder.
When you see this screen you'll have to have an RDS connection to the source you will be working with. If you are going to be using a data source on your own machine make sure you have RDS services running. (Check in your ColdFusion Server folder and run the "ColdFusion RDS Services.") Drill into the Customer table and click on New Query.
Choose the shelleyCatalog data source and select New Query. Now you will be able to choose which table from the shelleyCatalog you would like to use. If you would like to use another when building a query, right-click and choose Add Table where you will be able to select from a list of all the other tables available from the data source you are working in. For this example we will just be using the Customer table.
FIGURE 115 As you choose your fields, the query statement is automatically built for you.
By double clicking on the wildcard * you will choose all fields in the table. As you will notice in the bottom window, the SQL statement is built for you. Once the query statement is built, select the RUN Query button and the query will execute. This is used to validate the query.
FIGURE 116 The results from running the SQL builder.
This can also be helpful when working with several tables at once. With a little investigation, it can really save you some time!