0
$\begingroup$

Any idea how to drop duplicate values by 2 columns?

Here is the example. I want to get the first row if there's a duplicate value by 2 columns (customer_id , orderid)

Example

I've done with making a count distinct by new variable (concat customer id and order id ), but the value isn't correct yet.

$\endgroup$

1 Answer 1

0
$\begingroup$

To solve this inside Tableau worksheet: use Index() calculation by cust_key and filter out anything not equal to 1. enter image description here

But usually this type of things are handled in the initial SQL.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.