question

PaulHernandez-8067 avatar image
0 Votes"
PaulHernandez-8067 asked PaulHernandez-8067 answered

SSDT - Publish script for users from external provided not generated correctly

Hi everyone,

I created some users using this syntax:

 CREATE USER [MY_USER] FOR EXTERNAL PROVIDER;

After a schema compare using Visual Studio 2019 Data Tools and generating a script to publish the changes I got this generated:

 CREATE USER [MY_USER] WITHOUT LOGIN;

Which is not the expected behaviour.

Is this a limitation or am I missing some configuration?



azure-sql-database
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

AnuragSharma-MSFT avatar image
0 Votes"
AnuragSharma-MSFT answered

Hi @PaulHernandez-8067, welcome to Microsoft Q&A forum.

I tried to follow the steps mentioned by you and was able to reproduce the issue exactly as you mentioned.

I was trying to look for solution and I found a similar issue logged as below:

Azure SQL Drop and Create AAD User During Every Deploy - FOR EXTERNAL PROVIDER

Solution of it mentioned to install latest versions of VS and SSDT. After I updated both and tried to generate the script I was able to generate it properly. I then ran the script successfully on target database as well. Please check the below screenshot for the same.

81084-image.png

You can go to Visual Studio Installer and update the VS and SSDT. Below is the link for SSDT update:

SSDT for Visual Studio 2019

Please let me know if this helps or else we can discuss further.


If answer helps, please mark it 'Accept Answer'





image.png (14.2 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

PaulHernandez-8067 avatar image
0 Votes"
PaulHernandez-8067 answered

Hi @AnuragSharma-MSFT ,

many thanks for the quick support. Upgrade VS and the Data Tools to the following version has solved the issue as proposed:

81047-image.png



Cheers,
Paul


image.png (34.9 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.