点击此处---> 群内免费提供SAP练习系统(在群公告中)
加入QQ群:457200227(SAP S4 HANA技术交流) 群内免费提供SAP练习系统(在群公告中)
合并到" TESTDB"中。" Customers_2"" M"使用(选择" T"。"地址"," T"。"城市"," T"。" CompanyName"," T"。" ContactName", " T"。" ContactTitle"," T"。"国家"," T"。"客户ID"," T"。"传真"," T"。"电话"," T"。"邮政编码"," T "。" Region" FROM" Scd_5492_ASTWK_2"" T")T ON(" M"。" CustomerID" =" T"。" CustomerID")匹配时(MAP(" T"。"地址"," M"。 "地址",0、1)= 1或MAP(" T"。"城市"," M"。"城市",0、1)= 1或MAP(" T"。"公司名称"," M"。 " CompanyName",0,1)= 1 OR MAP(" T"。" ContactName"," M"。" ContactName",0,1)= 1 OR MAP(" T"。" ContactTitle"," M"。 " ContactTitle",0,1)= 1 OR MAP(" T"。"国家"," M"。" Country",0,1)= 1 OR MAP(" T"。"传真"," M"。 " Fax",0,1)= 1 OR MAP(" T"。" Phone"," M"。" Phone",0,1)= 1 OR MAP(" T"。" PostalCode"," M"。 " PostalCode",0,1)= 1或MAP(" T"。" Region"," M"。" Region",0,1)= 1)然后更新集" Address" =" T"。" Address" ," City" =" T"。" City"," CompanyName" =" T"。" CompanyName"," ContactName" =" T"。" ContactName"," ContactTitle" =" T"。" ContactTitle"," 国家" =" T"。"国家","传真" =" T"。"传真","电话" =" T"。"电话"," PostalCode" =" T"。" PostalCode"," Region" =" T"。" Region";
嗨,我有一个查询,给出以下错误。
sql语法错误:必须存在WHEN MATCHED子句或WHEN NOT MATCHED子句中的至少一个。:第1行col 1(在pos 0)
没有表来运行您的语句,我无法在HANA 2 SP04上重现此错误。
但是,我怀疑可能有悬挂的支架或类似的东西。 除了语法检查器之外,我知道处理此类问题的最好方法就是使该语句更易于阅读。
当您摆脱了不必要的引号(不是表别名时,请继续。) )和检查地址字段是否不同的超级怪异方法(为什么不使用相等条件?),您可以得到如下语句:
不确定您的身份,但是对我来说,这更容易阅读。
此外,这种形式在我的测试实例(由伪表/数据组成)上也可以正常工作。
一周热门 更多>