메뉴 건너뛰기

SAP 한국 커뮤니티

<b>[완료]</b>cursor 프로그램 관련 질문입니다.

order001 2007.12.05 00:42 조회 수 : 9789 추천:30

data: c type cursor,
      wa type sbook.


open cursor c for
     select carrid connid fldate bookid smoker
     from   sbook
     where carrid = 'LH'
     order by carrid connid fldate smoker bookid.


 fetch next cursor c into corresponding fields of wa.

 while sy-subrc = 0.
   if  wa-smoker = ' '.       ==> '  ' 의 의미는 null값인가요?
     perform nonsmoker using c.
    
   elseif  wa-smoker = 'X'.
     perform smoker using c.
     skip.
    
   else.
     exit.
  


endif.
  
  endwhile.
 


  form nonsmoker using n_cur type cursor.
   while wa-smoker = ' ' and sy-subrc = 0.
     format color = 5.
      write: / wa-carrid, wa-connid, wa-fldate, wa-bookid.
      fetch next cursor n_cur into corresponding fields of wa.
  endwhile.
  endform.


  form smoker using s_cur type cursor.
   while wa-smoker = 'X' and sy-subrc = 0.
     format color = 6.
     write: / wa-carrid, wa-connid, wa-fldate, wa-bookid.
     fetch next cursor s_cur into corresponding fields of wa.
   endwhile.
  endform.


 


 


 

번호 제목 글쓴이 날짜 조회 수
6526 <b>[완료]</b>테이블 유지보수 뷰 관련 질문 입니다. [4] 안면도 2007.12.06 14862
6525 [요청]펑션 LVC_TRANSFER_FROM_SLIS, LVC_FIELDCAT_COMPLETE의 용도가 궁금합니다. [2] 아밥맨 2008.06.10 14597
6524 parameter ID 확인하는 방법? [2] dhs 2019.11.22 13794
6523 <b>[완료]</b>CBO의 약자가 무엇인가요?(CUSTOMER BOLT ON) [6] sapjoy 2008.11.21 13501
6522 [요청]T-CODE KO02 내부오더변경에서 문의사항이 있습니다. [2] 이쁜진. 2007.12.08 13487
6521 <img src=2.gif>메일보내기(outlook) 방법 혹은 자료 부탁드립니다 [13] 츄리닝 2009.11.18 13416
6520 <b>[완료]</b>dataset에 관한 질문입니다. [5] FIFIFI 2007.12.04 13270
6519 <b>[완료]</b>라디오 버튼 입고구분 어떻게 해야하나요? [4] hogun 2008.02.29 12344
6518 <b>[완료]</b>관계연산자의 의미를 알고싶습니다. [3] 다급 2008.06.30 11539
6517 [요청]Modify 와 Modify Table 의 차이좀 알고싶어요~ [4] 아밥걸 2008.07.10 11442
6516 <b>[완료]</b>Internal table을 만든 table로 데이터를 옮기려고 하는데 잘 안되네요. [10] 행복한외계인 2008.01.22 11424
6515 <b>[완료]</b>call transaction 사용하는 방법 좀 가르쳐주세요. [8] 행복한외계인 2007.11.22 11188
6514 <b>[완료]</b>sy-index와 sy-tabix의 차이가 궁금합니다. [7] kkk 2008.02.27 10960
6513 [질문] alv에서 필드 폭의 길이를 지정할 수 없나요? [5] 나도아밥퍼 2007.05.23 10706
6512 <b>[완료]</b>"DESCRIBE TABLE ~~~ LINES " 관련 질문입니다. [2] tenyearsago 2009.01.05 10694
6511 [요청]인터널테이블 끼리 move-corresponding 안될까요~~ [5] genius 2008.03.14 10551
6510 [요청]GETWA_NOT_ASSIGNED 이 오류에 대해서 아시는 분? [7] 나도아밥퍼 2008.01.08 10337
6509 <b>[완료]</b>오라클의 CASE WHEN과 같은 기능.. [8] 풍뎅이 2007.12.06 10233
6508 [요청]ALV 에서 수량 필드 소숫점 없애는 방법 [5] 파릇이 2008.06.12 9971
» <b>[완료]</b>cursor 프로그램 관련 질문입니다. [4] order001 2007.12.05 9789