메뉴 건너뛰기

SAP 한국 커뮤니티

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

order001 2007.12.05 00:42 조회 수 : 9792 추천: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.


 


 


 

번호 제목 글쓴이 날짜 조회 수
927 <b>[완료]</b>조건 [2] 풍뎅이 2007.12.11 1756
926 <b>[완료]</b>CALL SCREEN과 SET SCREEN의 차이가 무엇인가요? [3] SARA 2007.12.11 2752
925 [요청]왕기초질문 LEFT OUTER JOIN [4] 벤또 2007.12.11 7631
924 [요청]HR_MX_INTERVAL_BETWEEN_DATES 풍뎅이 2007.12.10 1662
923 [요청]OCCURS 0 에대한 질문입니다. [3] kkk 2007.12.10 3382
922 <b>[완료]</b>select 문에 대한 질문입니다. [3] 윤군친구(bsp개발자) 2007.12.10 1816
921 <b>[완료]</b>LDB 생성을 통한 report 프로그램 만들기.. [2] 박준상 2007.12.10 2300
920 [요청]GUI_DOWNLOAD 사용중 궁금한 점이 있습니다. [2] 초향이 2007.12.08 2317
919 <b>[완료]</b>입력받은 월보다 두달전의 달을 찾고 싶은데 잘안되네요. [2] 행복한외계인 2007.12.08 1805
918 [요청]T-CODE KO02 내부오더변경에서 문의사항이 있습니다. [2] 이쁜진. 2007.12.08 13487
917 <b>[완료]</b>F4헬프에서 값을 가져온후 바로 특정필드에 값 넣어주기. [3] huni special 2007.12.08 1845
916 [re] [요청]F4헬프에서 값을 가져온후 바로 특정필드에 값 넣어주기. file with SAP 2007.12.08 1732
915 <b>[완료]</b>Gui->WEB 호출시 파라미터 문제 [2] 윤군친구(bsp개발자) 2007.12.08 9575
914 <b>[완료]</b>사진 업로드 펑션에 관한 질문입니다. [6] mean 2007.12.08 3297
913 [요청]구매요청(PR) 텍스트화면 크기를 조정하려면 어떻게 해야 하나요? file 노름마치 2007.12.08 15231
912 <b>[완료]</b>SAP 로그인이 안됩니다.. [2] lunar 2007.12.07 1701
911 [요청]BC관련질문입니다. ECC,BW와같은 2개의 시스템이 한 서버의 data를 바라볼수 있는지.. 윤군친구(bsp개발자) 2007.12.07 1826
910 <b>[완료]</b>BDC에서 CATT 모드는 무엇을 의미하나요? [1] SARA 2007.12.07 3368
909 [요청]로그인시..please logon with a dialog user이게 뜹니다..ㅜㅜ [1] 피크민 2007.12.07 2511
908 <b>[완료]</b>checkbox를 쓰다가 궁금한게 떠올라서 질문올립니다. [3] SAP폐인 2007.12.07 2483