

SAC Imports and Unique constraint Violated issue
source link: https://blogs.sap.com/2021/11/11/sac-imports-and-unique-constraint-violated-issue/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

SAC Imports and Unique constraint Violated issue
Hello All, here is quick blog on one of the common issues faced during SAC imports and the resolution for the same.
The Preface:
SAP recommends using the Content Network Storage for all your SAC object transports. This blog focuses on a solution to one of the common transport errors if you are compelled to use to ‘File System’ approach. If you want to learn about transports, refer to my blog SAC transports 101.
I want to clarify here that I was forced to use the ‘File System’ option (even though it is not recommended by SAP) since my Content Network Storage won’t respond fine to my exports.
The Error:
Error: dberror(PreparedStatement.executeUpdate): 301 – unique constraint violated: Table(sap.fpa.services.contentlib.catalog::ContentCatalog.PUBLISHED_RESOURCE), Index(_SYS_TREE_RS_#634630_#0_#P0)
Root cause:
For some reason, the system DB (HANA DB in this case) which holds the metadata of these objects, fails to overwrite the primary key of the dashboard being imported. This happens to only the dashboards all the time. Wranglers, connections and dimension come clean during imports.
The Fix:
The .tgz file could be imported through ‘Drop Objects’ import option (in addition to ‘Update Objects’). This would unblock them. It acts like a drop and recreate command on the HANA DB itself forcing the object to be dropped and recreated with the same identifier.
Try the above approach if you encounter the Unique constraint error during your SAC imports in destination. Let me know if any questions / clarifications.
Regards,
Dhyanesh
Recommend
-
128
今年的 Google I/O 上谷歌发布了新版本的ConstraintLayout,但是我们并没有从中得到多少信息,只有一篇非常简陋的 博客 。 那么到底是哪些新特性,它们的功能和用法又是怎么回事呢? Percent Dimensions 说到Percent Dimensions就不得不说ConstraintLayout中
-
52
README.md graphql-constraint-directive
-
52
README.md Cosyan DB Cosyan DB is a transactional RDBMS with sophisticated multi table constraint logic. The long term goal of the project is to elimina...
-
58
In theprevious post, we have explained how to create UI elements like UILabel, UIButton etc using code. In this post, we will look into how to create Auto Layout constraint using code. This post assume you already know s...
-
27
about alloy* retains the syntax of Alloy : predicate logic + relational algebra permits higher-order quantification
-
23
MySQL 8.0.16 introduces the SQL CHECK constraint feature. This is one of the most requested and long awaited features for MySQL. This post describes the details of the feature. Let’s get started! Introduction...
-
6
Sujit Honrao May 16, 2022 1 minute read ...
-
8
Clang Static Analyzer and the Z3 constraint solver Notes on using the Z3 constraint solver with the Clang Static Analyzer June 21, 2022 · 3 min ...
-
10
Search Questions and Answers
-
8
Anthony Sciascia 52 minutes ago Issue with combination of data in SAC 15 Views
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK