Oracle字符串连接符||
Oracle中利用字符串连接符||(即双竖线)来连接查询结果。
案例1、字符串连接符||:
select '姓名:' || c.stuname || ', 课程:' || b.coursename || ', 成绩:' || a.score || '分。' as sxcj from score a, course b, stuinfo c where a.courseid = b.courseid and a.stuid = c.stuid
结果如下:
Oracle中利用字符串连接符||(即双竖线)来连接查询结果。
案例1、字符串连接符||:
select '姓名:' || c.stuname || ', 课程:' || b.coursename || ', 成绩:' || a.score || '分。' as sxcj from score a, course b, stuinfo c where a.courseid = b.courseid and a.stuid = c.stuid
结果如下: