1
votes

We have a sample worksheet, working off some data source like sample superstore (for example sake)

We use another data source like user_details which has data like

<!DOCTYPE html>
<html>
<head>
<style>
table {
    font-family: arial, sans-serif;
    border-collapse: collapse;
    width: 100%;
}

td, th {
    border: 1px solid #dddddd;
    text-align: left;
    padding: 8px;
}

tr:nth-child(even) {
    background-color: #dddddd;
}
</style>
</head>
<body>

<table>
  <tr>
    <th>ID</th>
    <th>Name</th>
    <th>Allow</th>
  </tr>
  <tr>
    <td>R4****3</td>
    <td>Vivek</td>
    <td>Y</td>
  </tr>
  <tr>
    <td>F5****8</td>
    <td>Srinivasan</td>
    <td>N</td>
  </tr>  
</table>

</body>
</html>

We blend this user_details data with superstore data to filter not allowed users, by data blending and adding a calculated field, which has a formula:

IF [ID] == USERNAME() AND [Allow] == 'Y'    
THEN 1    
ELSE 0    
END

As a result of this when we switch to Vivek I can see data in tableau desktop.

But we cannot see data when I switch to Srinivasan in tableau desktop.

When push these to changes to server, in normal mode it works fine, but when we clear all browser cache and cookies, and use tableau URL parameter -> “?:embed=y” the view does not load data for the user Vivek.

https://community.tableau.com/message/612072#612072

Attached is the workbook and issue detail for reference here

Any help will be deeply appreciated.

1

1 Answers

1
votes

Without having a Tableau Server instance to test on right now, my first guess for why this is failing when using ?:embed=yis because you have a core license with the guest account enabled.

If that is the case, then disabling the guest account should resolve the issue since whoever views the workbook will be prompted to log in and thus the USERNAME() function will work as expected.

If a core license and guest account is not in use, and Vivek logs in to view the embedded workbook but is still unable to view data as expected, then that sounds like a matter for Tableau Support to assist with.