# Debug Settings in the ColdFusion Administrator

ColdFusion can provide important debugging information for every application page requested by a browser. When enabled, debugging output is shown in a block following normal page output.

For detailed information on the debugging and logging settings in the ColdFusion Administrator, see Administering ColdFusion Server.

Note | By default, when you enable any of these options, debug output becomes visible to all users. You can, however, restrict debug output by using the Restrict debug output to selected IP address form at the bottom of the Debug Settings page.

## Generating debug information for an individual page

You can view the parameters and CGI environment variables for an individual application page without turning on the global debug settings in the ColdFusion Administrator. Simply append the parameter "mode=debug" to the end of the URL.

    www.myserver.com/cfdocs/test.cfm?mode=debug

## Generating debug information for an individual query

You can view debug information for an individual query by putting the DEBUG attribute into the opening CFQUERY tag:

    <CFQUERY NAME="TestQuery" DATASOURCE="CompanyInfo" DEBUG>
        SELECT * FROM TestTable
    </CFQUERY>

When this query runs, it places the debug information into the output page where the query is placed.

## Error messages

If ColdFusion is unable to fulfill a request because of an error, it returns a diagnostic message to the user. The message includes a link that allows the user to email a report of the error to the site administrator. You enable this feature in the Mail Logging page of the ColdFusion Administrator. Errors are written to a log file for later review.

ColdFusion returns:

- Database errors, including the ODBC error code, the extended error message returned fromt the ODBC driver, the name of the data source, and the SQL statement submitted to the database.
- Syntax error, including the line of the application page file on which the error occurred.
- System-related errors, such as out of memory conditions, or file or disk access errors.

Tip | If you get a message that does not explicitly identify the cause of the error, check on key system parameters like available memory and disk space.

For information on using the Logging settings and Mail Logging settings, see Administering ColdFusion Server