Computed column should do it :-)
"This e-mail is from Reed Exhibitions (Gateway House, 28 The Quadrant, Richmond, Surrey, TW9 1DN, United Kingdom), a division of Reed Business, Registered in England, Number 678540. It contains information which is confidential and may also be privileged. It is for the exclusive use of the intended recipient(s). If you are not the intended recipient(s) please note that any form of distribution, copying or use of this communication or the information in it is strictly prohibited and may be unlawful. If you have received this communication in error please return it to the sender or call our switchboard on +44 (0) 20 89107910. The opinions expressed within this communication are not necessarily those expressed by Reed Exhibitions." Visit our website at http://www.reedexpo.com -----Original Message----- From: Robert Rawlins To: CF-Talk Sent: Mon Mar 05 09:47:17 2007 Subject: M$SQL: Treat two columns as one Hello Guys, I'm looking to pull a set of records from the database but treat two of the columns as one, I'll also need to GROUP BY on that combined column, so somthing like this. SELECT Col1 & Col2 AS ColCombined FROM MyTable WHERE Col1 LIKE '%foo%' GROUP BY ColCombined Does that make sense? Basicly this is a single string that is split when its entered into the database and needs to be combined on its way out. They are also pulled from the database as seperate entities on a regular basis in a different query, thats why they're split on the way in. If this isnt possible then i'll just build in another 'combined' column into the database, but i'd rather avoid that duplication. Thanks guys, Rob ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Upgrade to Adobe ColdFusion MX7 The most significant release in over 10 years. Upgrade & see new features. http://www.adobe.com/products/coldfusion Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:271503 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

