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
 General SQL Server Forums
 New to SQL Server Programming
 COALESCE type error

Author  Topic 

tpiazza55
Posting Yak Master

162 Posts

Posted - 2007-02-07 : 16:00:58
i have 2 columns which are decimal

one is alway empty and the other always has a value -- i just need which ever one has a value -- i keep getting Error converting data type varchar to numeric

(COALESCE(TicketLoadQty, '') + ' ' + COALESCE(TicketTimeQty, '')) as theQuantity

how do i get around this

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2007-02-07 : 16:25:09
COALESCE(convert(varchar(20), TicketLoadQty), '')

same for the second one



Go with the flow & have fun! Else fight the flow
blog thingie: http://weblogs.sqlteam.com/mladenp
Go to Top of Page
   

- Advertisement -