2017-02-10 2 views
0

안녕하십니까. 머지 (MERGE)에 대한 DB2 설명서 (https://www.ibm.com/support/knowledgecenter/ssw_ibm_i_71/sqlp/rbafymerge.htm)를 따라 왔으며 아래 문을 작성했습니다. 그러나 이것은 아래의 오류와 함께 실패SQL 병합이 작동하지 않습니다.

MERGE INTO TEMP2 target USING TEMP1 source 
    ON target.ITNBR = source.ITNBR   
      AND target.STID = source.STID  
      AND target.ITRV = source.ITRV  
WHEN NOT MATCHED THEN      
    INSERT VALUES(TEMP1.*)     
WHEN MATCHED THEN       
    UPDATE SET ITNBR = source.ITNBR 

:

키워드 SOURCE는 예상되지 않음. 유효한 토큰 : 전체 왼쪽 십자말 RIG

나는 여기서 무엇이 잘못된지 잘 모르고있다. 누군가 제발 도와 줄 수 있니?

답변

2

SOURCE는 DB2 키워드이므로 문제가됩니다. 나는 그것을 다른 단어로 바꿨고 보석처럼 작동한다. 왜 IBM은 공식 문서에서 그러한 예를 제시 했습니까?

+0

어쩌면 당신은 고정 얻기 위해 IBM과 함께 문서 PMR을 열어야합니다. – jmarkmurphy

+0

예 표시! 이 작업을 수행하는 방법을 모르지만 확실히 알아낼 것입니다. 희망 아무도 이것에 가야하고 코드 조각을 미친 듯이 완료하려고 할 때 시간을 낭비하지 않습니다. P –

+0

@ user3311539 링크 된 페이지의 하단에 '피드백'링크가 있으며 하단에는 '연락처'링크가 있어야합니다. 그렇지 않으면 IBM 지원 센터에 전화 또는 이메일로 문의하십시오. – user2338816

0

그래서 IBM이이 문제가 확인되었습니다 이후 릴리스에서 시정하기로 합의했다 :

From: Nathan R Skalsky [mailto:[email protected]] 
Sent: Tuesday, February 14, 2017 4:34 AM 
To: Thejwal Pavithran <[email protected]> 
Subject: RE: Feedback to IBM Knowledge Center - Content page/ssw_ibm_i_71/IBM i 7.1 

Hi Thejwal, 

Unfortunately, this is not our normal channel of communication; Therefore, I will not be posting to the specified thread. 
Your welcome to communicate it. 

Thanks, 

Nathan R. Skalsky 
IBM i Software Engineer - DB2 for IBM i Development 
________________________________________ 

E-mail: [email protected] 
Internal: Nathan R Skalsky/Rochester/IBM 


3605 Hwy 52 N 
Rochester, MN 55901-1407 
United States 





From:  Thejwal Pavithran <[email protected]> 
To:  Nathan R Skalsky/Rochester/[email protected] 
Date:  02/13/2017 11:53 AM 
Subject:  RE: Feedback to IBM Knowledge Center - Content page/ssw_ibm_i_71/IBM i 7.1 
________________________________________ 



Thanks Nathan! 

Would be great if you could post a reply on the Stack Overflow thread for the sake of all users. 

Thanks, 
Thejwal 


     Thejwal Pavithran | IBMi Developer 
     7th Floor, ‘Electra’, Wing A, Prestige Tech Park, Marathalli| Bangalore – 560103 | Karnataka 
     Direct line: | Cell: +91 9620661497 
     [email protected]| www.polaris.com 

From: Nathan R Skalsky [mailto:[email protected]] 
Sent: Monday, February 13, 2017 11:21 PM 
To: Thejwal Pavithran <[email protected]> 
Subject: Feedback to IBM Knowledge Center - Content page/ssw_ibm_i_71/IBM i 7.1 

Hi Theywal, 

Thank you for your bringing this to my attention. We will fix this in a future technical refresh (TR) of the SQL Programming topic in 7.2 and 7.3. 
The fix will remove the word SOURCE from these examples. 

Thanks, 

Nathan R. Skalsky 
IBM i Software Engineer - DB2 for IBM i Development 
________________________________________ 

E-mail: [email protected] 
Internal: Nathan R Skalsky/Rochester/IBM 


3605 Hwy 52 N 
Rochester, MN 55901-1407 
United States 




Thejwal Pavithran ---02/12/2017 03:08:33 AM---Hi Team, Have come across a minor issue in DB2 MERGE syntax at below page. 

From: Thejwal Pavithran <[email protected]> 
To: IBM Knowledge Center/Pittsburgh/[email protected] 
Date: 02/12/2017 03:08 AM 
Subject: Feedback to IBM Knowledge Center - Content page/ssw_ibm_i_71/IBM i 7.1 
________________________________________ 




Hi Team, 
Have come across a minor issue in DB2 MERGE syntax at below page. 
URL: https://www.ibm.com/support/knowledgecenter/ssw_ibm_i_71/sqlp/rbafymerge.htm 
Issue described here: 
http://stackoverflow.com/questions/42151989/sql-merge-not-working/42152283?noredirect=1#comment71511658_42152283 
Please attempt to rectify. 
Thanks, 
Thejwal 


    Thejwal Pavithran | IBMi Developer 
     7th Floor, ‘Electra’, Wing A, Prestige Tech Park, Marathalli| Bangalore – 560103 | Karnataka 
     Direct line: | Cell: +91 9620661497 
     [email protected]| www.polaris.com 


Thanks, 

Nathan R. Skalsky 
IBM i Software Engineer - DB2 for IBM i Development 
________________________________________ 

Phone:(507) 253-1685 
T/L: (507) 553-1685 
Fax: (507) 253-4728 
Office: 15-3 C118 
E-mail: [email protected] 
Internal: Nathan R Skalsky/Rochester/IBM 


3605 Hwy 52 N 
Rochester, MN 55901-1407 
United States 

CONFIDENTIAL: The information contained in this email communication is confidential information intended only for the use of the addressee. Unauthorized use, disclosure or copying of this communication is strictly prohibited and may be unlawful. If you have received this communication in error, please notify us immediately by return email and destroy all copies of this communication, including all attachments.