Get Inspire insights from former attendees in our AMA discussion thread on Inspire Buzz. ACEs and other community members are on call all week to answer!

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Getting Windows Username from Gallery User

OverSQL
7 - Meteor

Greetings Fellow Alterians

 

I am trying to extend some apps being run through the gallery and was really hoping to be able to pass back in the username from the gallery for use in a workflow (essentially to limit the selection in a dropdown). 

 

I have been provided with a workflow that grabs the UPN (which is in the form andrew@test.com) but I need to resolve this to domain\username in order it to be used against the database (to return only tables that the user has rights to see).  My idea would be to have a stored proc or script which allows the user name to be passed into which would run the query as the effective user. 

 

Has anyone done this before or can provide any advise on approach.  I was going to use Get-ADUser commandlet to get back the Windows user name, but wondering if any other simpler solutions.

 

Many thanks if you can assist.

 

Cheers


Andrew

 

 

 

4 REPLIES 4
patrick_digan
17 - Castor
17 - Castor

@OverSQL We've used the windowsIdentitys table which has a field called name and is equal to "Domain\username" that you're looking for. It has an email you could match on or an id field as well.

 

Capture.PNG

OverSQL
7 - Meteor

Hi Patrick

 

Sorry for the belated reply.  Thanks for the solution

 

Cheers

 

 

Andrew

daviskb
7 - Meteor

The _ID field in the windowsIdentiys collection is different than the _ID field in the Users collection.  Also, it does not match the __Cloud:ID.  Any idea why

sanket277
7 - Meteor

Thanks @patrick_digan for the solution

 

Unfortunately, our company policy does not allow the Alteryx server or Mongo DB credentials to be shared. Do you know if there is any other solution to fetch the credentials (User ID, Name, Email, etc.) of the user who's executing a given workflow by logging in to the Alteryx server (gallery). I am using Alteryx 2018.4 version.

 

Any help in this matter would be greatly appreciated!! Thanks in advance!!

Labels