Last active
May 18, 2018 02:52
-
-
Save alevyinroc/3185d1b9bf219005509ff82f9b91bd33 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-Content TableList.txt | Foreach-Object {Get-DbaTable -ServerInstance MYSERVER -Database satellites -Table $PSItem | ForEach-Object {$PSItem.Columns | Select-Object Name,DataType,Nullable,@{name='Length';expression={$_.Properties["Length"].Value}} | Export-Excel -Path C:\Users\andy\Documents\TableInfo2.xlsx -WorkSheetname $PSItem.Name -FreezeTopRow -BoldTopRow}} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment