select rsi.shape_name as shape_name,
rsi.slot_index as slot_index,
rsi.slot_size - rsi.slot_index as slot_size,
case rsi.slot_type when null then ''
else rsi.slot_type
end slot_type
from rics_shape_info rsi, rics_dev rd, rics_reset rs
where rsi.switch_id = rd.switch_id
and rd.rics_code = rs.rics_code
and rs.mp_info = rsi.head_slot || '/' || rsi.body_slot
and rsi.switch_id = 'SLMODLTTE0'
and rsi.head_slot = 'ASS04'
and rsi.body_slot = 'TLDLR'
order by
rsi.slelter_number desc,
case slot_type when 'TOP' then '1'
when 'BODY' then '2'
when 'BODY_M' then '3'
when 'BOTTOM' then '4'
end,
slot_index
위 쿼리와 다음 테이블을 조인 하고 싶은데
select * from rics_shape_info_tmp
이테이블은
create table rics_shape_info_tmp
(
slelter_number varchar(16) not null -- slelter number
)
lock datarows
on 'default'
이렇게 생겼고 데이타는
slelter_number
=============
SHELF5
SHELF4
SHELF3
SHELF2
SHELF1
SHELF0
=============
이렇게만 데이타가 들어가 있습니다.
a.slelter_number =* b.slelter_number
이런식으로 넣어볼려고 했는데 안되네요
고수님들 방법좀 알려주세요
|