"Append to DataSet" method is creating duplicates
In a nutshell:
1) create & build the initial dataset in workbench
SELECT * FROM myTable
-- WHERE StartDateTime > '!{lastvalue:StartDateTime}!'
ORDER BY StartDateTime
2) update job method from Replace to Append:
a) uncomment my WHERE clause in my query
b) update/add "replacement variable" subtab
Column = StartDateTime
Value = !{lastvalue:StartDateTime}!
c) switch dataset to append
d) save & run
Results: the dataset job appends new records as expected, the only issue is the occasional duplicate record (and sometimes triplicate records). I know I can remove the duplicates with a dataflow, but shouldn't have to...
Any ideas why the duplicates are happening?
We also have a couple other append dataset jobs, they've all running fine for months (except for random duplicate/triplicates). I have experimented with other queries, using primary keys instead of DateTime, same issue - happening with all append dataset jobs, not just this specific one.
Thanks
edit: added code tags in attempt to remove emoticon/smiley... : S
Comments
-
I can't tell you why, but I can tell you that we experienced some of the same issues with replacement variables.
In some instances we decided to take a different approach by creating multiple replacement datasets of different timeframes and stacking them into one.
In other cases we've kept the append, removed the replacement variable, and used a relative date, like trx_date=sysdate-1, or something similar. We haven't seen duplicates with this method.
Aaron
MajorDomo @ Merit Medical
**Say "Thanks" by clicking the heart in the post that helped you.
**Please mark the post that solves your problem by clicking on "Accept as Solution"1 -
Hi,
So the Problem which your curently facing is because timestamp value which your using for incremental records. Even i have faced the same thing and have dropped a mail to DOMO support but as of now you cant control the syntax of the replcament variable , so you have to use the data flow for creating this.
If our database has date insted of timestamp use that am sure you wont se any duplicates , also make sure to cast it in the right way.
0
Categories
- All Categories
- 1.8K Product Ideas
- 1.8K Ideas Exchange
- 1.5K Connect
- 1.2K Connectors
- 300 Workbench
- 6 Cloud Amplifier
- 8 Federated
- 2.9K Transform
- 100 SQL DataFlows
- 616 Datasets
- 2.2K Magic ETL
- 3.9K Visualize
- 2.5K Charting
- 738 Beast Mode
- 57 App Studio
- 40 Variables
- 685 Automate
- 176 Apps
- 452 APIs & Domo Developer
- 47 Workflows
- 10 DomoAI
- 36 Predict
- 15 Jupyter Workspaces
- 21 R & Python Tiles
- 394 Distribute
- 113 Domo Everywhere
- 275 Scheduled Reports
- 6 Software Integrations
- 124 Manage
- 121 Governance & Security
- 8 Domo Community Gallery
- 38 Product Releases
- 10 Domo University
- 5.4K Community Forums
- 40 Getting Started
- 30 Community Member Introductions
- 108 Community Announcements
- 4.8K Archive