Skip to contents

After polis_upsert() reduces the data to one row per id, checks whether multiple Ids share the supplied business key. Matching rows are flagged for review and retained in the data.

Usage

flag_ambiguous(data, key, id = "id", sink = NULL)

Arguments

data

A data frame (already deduped by id).

key

Character vector naming the business key columns.

id

Name of the identifier column (default "id").

sink

Optional destination for the flagged rows: a file path (CSV is written) or NULL (flags are attached as the polis_ambiguous attribute).

Value

data, unchanged, possibly carrying a polis_ambiguous attribute.