tracker issue : CF-3039142

select a category, or use search below
(searches all categories and all time range)
Title:

Bug 78546:(Watson Migration Closure)My datasourceless <cfquery name="etc" /> syntax request has been accepted and implemented in CF9, which is FANTASTIC ( thank you )! It’s simple and powerful and provides a singular benefit: exempting

| View in Tracker

Status/Resolution/Reason: Closed/Won't Fix/

Reporter/Name(from Bugbase): David McGuigan / David McGuigan (David McGuigan)

Created: 07/05/2009

Components: Database, CFQuery

Versions: 9.0

Failure Type: Unspecified

Found In Build/Fixed In Build: 0000 /

Priority/Frequency: Normal / Unknown

Locale/System: English / Platforms All

Vote Count: 0

Problem:

My datasourceless <cfquery name="etc" /> syntax request has been accepted and implemented in CF9, which is FANTASTIC ( thank you )! It’s simple and powerful and provides a singular benefit: exempting you from source code redundancy by centralizing configuration to a single line of code.

We should extend the metaphor to the next two tiers by providing two more granular forms of defaults for datasourcing before 9 launches and legacy Luddites can argue backwards compatibility issues.

<cfset request.datasource = "datasource2" /> to override the application default on a per-request basis and

<cfset variables.datasource = "datasource3" /> ( and similarly attributes.datasource where appropriate ( cfthread, etc. ) ) to override both the request default and the application default.

This would provide some supercharged flexibility and would multiply the benefits of the per-application implicit datasourcing. A CFC instead of being littered with references like datasource="#variables.datasource#" would benefit from the code exemption the same way that consumers of the per-app datasource do. So would custom tags, templates being executed as modules, and a variety of other examples.

Because no previous CFML exists without explicitly providing a datasource, this is a solid opportunity to "get it right the first time through", as looking for the datasource default in the appropriate scope order will only apply to CF9-or-newer code. Thanks!
Method:


Result:

----------------------------- Additional Watson Details -----------------------------

Watson Bug ID:	3039142

External Customer Info:
External Company:  
External Customer Name: David McGuigan
External Customer Email: 5E0D54C04462BF5E992016B6
External Test Config: 07/05/2009

Attachments:

Comments: