May 31, 2022 at 7:00 am
Team,
For an Azure PaaS SQL Database; I am trying to Generate the List of Users in the Database along with their Associated Permissions using Windows PS Command Export-DBAUser. However I receive the below error message. Can someone please help.
You cannot call a method on a null-valued expression.
At C:\Program Files\WindowsPowerShell\Modules\dbatools\1.1.101\allcommands.ps1:23090 char:13
+ $versionNameDesc = $versionName[$scriptVersion.ToString() ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : InvokeMethodOnNull
Exception setting "TargetServerVersion": "Cannot convert null to type "Microsoft.SqlServer.Management.Smo.SqlServerVersion" due to enumeration values that are not
valid. Specify one of the following enumeration values and try again. The possible enumeration values are
"Version80,Version90,Version100,Version105,Version110,Version120,Version130,Version140,Version150"."
At C:\Program Files\WindowsPowerShell\Modules\dbatools\1.1.101\allcommands.ps1:23095 char:17
+ ... $ScriptingOptionsObject.TargetServerVersion = [Microsoft. ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], SetValueInvocationException
+ FullyQualifiedErrorId : ExceptionWhenSetting
June 1, 2022 at 7:10 am
Thanks for posting your issue and hopefully someone will answer soon.
This is an automated bump to increase visibility of your question.
July 6, 2022 at 9:42 am
We have fixed this issue.
July 6, 2022 at 4:37 pm
and what was the fix? its good to post the solution in case any other users face the same issue.
July 6, 2022 at 4:40 pm
The Latest version of dbatools module; for export-dbauser asks the version as well; in the notes i see that there is no version been specified for azure paas database; i copied the dbatools module that i downloaded last year after which everything worked fine as expected.
July 6, 2022 at 5:19 pm
If there is a regression in the module you should report said regression to the GitHub repository so that one of the community developers can investigate it.
Please post your issue here so it may be fixed.
https://github.com/dataplat/dbatools
Additionally for DBATools related questions you will find more of the community development team on Slack
Use the #dbatools channel and post your question there.
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply