문제

I have got a the following query

    select tb2.customer_no, tb2.last_name, tb2.first_name
    from ccare.customer tb2
    where tb2.customer_no = '1000647'

which outputs

             customer_no    First name      Last name
             1000647          George              Roberts

How can I combine the First name and last name to appear in one column. The desired output would be

             customer_no       Name     
             100064        George Roberts
도움이 되었습니까?

해결책

Pretty simple. This should do it.

select tb2.customer_no, tb2.last_name || ' ' || tb2.first_name name
from ccare.customer tb2
where tb2.customer_no = '1000647'
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top