Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Transact-SQL (2000)
 Query to get 2 column values as one column

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2002-12-11 : 09:19:43
shariq writes "Hi

I want to use a select statement which gets two combined values in one column from two different columns .

Like

SELECT column1 column2 AS columnTotal FROM table


Plz answer it

i want to write 2 different values of different fields into one recordset field .


Thanks !"

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2002-12-11 : 09:26:46
SQL versions 1.00 and above include the new "+" operator!

Try:

SELECT column1 + column2 AS columnTotal FROM table


- Jeff
Go to Top of Page
   

- Advertisement -