hi hi yall, i have a question that I think should ...
# troubleshooting
t
hi hi yall, i have a question that I think should have an obvious answer, but I can’t figure it out… I have a tap that connects to Campaign Monitor (an email ESP), I have a stream that runs on “active subscribers” — from what I can see meltano always updates or adds people to our postgres target, but never removes them, even when I use --full-refresh option, it doesnt clean out the target and then add them all back, is there a way to do this with a meltano cmd? basically if someone unsubscribes at CM, I need to remove them from the “active subscribers” stream, I already get them on the “unsubscribed stream” - but they dont get removed from the active 😞 — is there a setting in the stream or tap that I can set? Sorry for the n00b question!
c
@tim_schwartz I had this question before as well. To do "hard delete", both the tap and target need to support the
ACTIVATE_VERSION
message which is an optional feature. The tap would need to emit that message when a record is deleted, and the target would need to handle it appropriately. I know that the default postgres target can handle
ACTIVATE_VERSION
, so you need to make sure that the tap supports it.
Also
--full-refresh
confused me as well. I similarly thought it clears out the target before doing a full synchronization. In reality, it just tells the tap to emit all records regardless of previous state. The target is not cleared out in any way.
t
right!
thank you, ill dig into ACTIVATE_VERSION
appreciated!
c
np!
t
is there another way to just clean the target before starting the sync? i do this as a nightly job and these streams aren’t particularly big
c
To my knowledge, no. You could drop or truncate the tables before doing a full refresh.
t
i guess i thought thats what full-refresh did
annoying!
🙂
Copy code
--full-refresh will force a full refresh and ignore the prior state. The new state after completion will still be updated with the execution results, unless --no-state-update is also specified.
i guess not
e
🙌 1