Question

What am I doing wrong with identify()?

  • 5 June 2019
  • 3 replies
  • 1334 views

Userlevel 2
Badge

Hey, Mixpanelers! I'm having some trouble re-assigning my users' Distinct IDs. In a perfect world, I'd like each user's Distinct ID to be their email address.


Here are the steps I followed:

1. When a user creates an account, I call mixpanel.alias(EMAIL_FROM_INPUT)

2. When a user logs in, I call mixpanel.identify(EMAIL_FROM_INPUT)


The good news:

Once a user logs in, every event they trigger in Live View has a Mixpanel property called User ID attached. That User ID is set to their correct email address.


The trouble:

With the exception of my own Distinct ID—which is correctly set to my email address—every user's Distinct ID is still the default string of numbers and characters.


Any ideas about what I might be getting wrong? Thanks so much!



3 replies

Userlevel 1
Badge

Hi @lisasiva,

The behavior you are seeing is expected behavior. This will keep your identity management aligned and in good health. To dig deeper into how Identity Management works, I would check out their video on identity management here and their identity management article. Hope this helps clarify!


Userlevel 2
Badge

@frank_bryant, thanks for the links and for your insight. One question that's still perplexing me: Why am I seeing my email address as my own Distinct ID, while every other user's email address is saved as their User ID?


Userlevel 1
Badge

@lisasiva hmm the thing that comes to mind is if you where calling identify when a user created an account and calling identify again when a user logged in. This would cause the Distinct ID to be set to your email. However, as mentioned before, this might not be ideal and we would want to alias on account created and identify on log in.


Reply


Mixpanel