Your questions answer is basically a matter of opinion. I, personally, would
only alias them when I cross join them. If I am only querying one of them, I
would probably just use the column name as the variable name.

..:.:.:.:.:.:.:.:.:.:.:.
Bobby Hartsfield
http://acoderslife.com



-----Original Message-----
From: Dawson, Michael [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, February 19, 2008 12:26 PM
To: CF-Talk
Subject: RE: Inconsistent Variable Names Across Data Sources

Sometimes, I have to join across all three datasources to get the data I
need.

For example, I need Active Directory, to get a list of current domain
accounts.  This is then joined to data exports from our business system
to get HR information.  Finally, this is joined to our ID Card database.

Each of these datasources has a field for a person's last name.

Active Directory: sn
Bus Sys Exports:  LAST_NAME
ID Card DB:       LastName

Therefore, I have three different options for specifying a column name
for a person's last name.  I have to choose one.  In this example, I
would probably choose the "sn" from Active Directory since it would be
the "controlling" data entity.

I would probably alias "sn" to "lastName" in my CF code, in this
example.  However, if I only need to query Active Directory, and no
other data sources, would I still alias the column or not?  In other
words, regardless of consistency, if my query doesn't include
"lastName", yet most of the CF code uses "lastName", should I not always
alias the column?  That is my question.

However, no matter what I choose for my CF variable, I will not match
the column names from the other two data sources.

m!ke

-----Original Message-----
From: Bobby Hartsfield [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, February 19, 2008 10:20 AM
To: CF-Talk
Subject: RE: Inconsistent Variable Names Across Data Sources

What is there to say really? Yes, consistency makes things easier in a
situation like this. But, things are much easier to follow, usually,
when the applications variable names match DB column names.

....:.:.:.:.:.:.:.:.:.:.:.
Bobby Hartsfield
http://acoderslife.com



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;160198600;22374440;w

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:299338
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to