Announcement

Collapse
No announcement yet.

MERGE Statement Works in SSMS But Not In Navicat

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • MERGE Statement Works in SSMS But Not In Navicat

    Hello -

    I have created a MERGE statement that runs nightly to refresh one of our production tables. When I first set this process up, I had some issues with the error, "> [42000] [Microsoft][SQL Server Native Client 11.0][SQL Server]A MERGE statement must be terminated by a semi-colon (. (10713)" .

    I found this article (below) and found that the query needed to be wrapped in BEGIN and END blocks. If you read the last reply in the article, you will see the post I am referring to.
    https://www.experts-exchange.com/que...rge-query.html

    Once I added those transaction blocks, my query worked fine and still works.

    Now I need to make some changes in my query and some of these changes include adding CASE statements. As soon as I add the CASE statements (or just one CASE statement), the same error occurs again:
    "> [42000] [Microsoft][SQL Server Native Client 11.0][SQL Server]A MERGE statement must be terminated by a semi-colon (. (10713)"

    I tested the query I need to use in Microsoft SQL Server Management Studio v14.0.17277.0 and the query ran without any problems. Are there any suggestions for this issue?

    My current versions:
    1) Navicat Premium 12.1.5

    2) Microsoft SQL Azure (RTM) - 12.0.2000.8
    Dec 19 2018 08:43:17
    Copyright (C) 2018 Microsoft Corporation

    Let me know if you need any additional details.

    Thanks,
    Michael

  • #2
    Please upgrade to the latest version 12.1.16 to see if it can solve the reported problem.

    If you still encounter the same problem, please provide the following information. You can send to - https://help.navicat.com/hc/zh-cn/requests/new

    1. Your OS version, i.e. macOS / Windows.
    2. The query you have ran.
    3. Screenshots showing the error.

    Comment

    Working...
    X