convert 3 different fields into one column | SQL Server Performance Forums

SQL Server Performance Forum – Threads Archive

convert 3 different fields into one column

I need to convert 3 different fields into one coulmn.
Sample Table – Cust_Dim
Table Fields – Cust_ID, Add, Cat_A, Cat_B, Cat_C New Table – New_Cust_Dim
Table Fields – Cust_ID, Add, Category Remark : Category(New_Cust_Dim) = Cat_A(Cust_Dim) + Cat_B(Cust_Dim) + Cat_V(Cust_Dim) How should i write an statement to execute it? Thank you Onn
hey there,
the amazing possibilites of SQL*Server 2000 give you the option of creating fields like this :: create table SampleTable
(
fieldA,
fieldB,
fieldC as fieldA + fieldB ) From this point on, I would create the field Category(New_Cust_Dim) on the former table and then select it from somewhere else … I dont think there is a way to referentiate fields from another table on the CREATE or ALTER TABLE statements.
]]>