PowerShell To Get Active Directory Users And Groups into SQL
Use Powershell to query AD for Users, Groups and GroupMembers
2019-09-19 (first published: 2016-03-31)
30,712 reads
Use Powershell to query AD for Users, Groups and GroupMembers
2019-09-19 (first published: 2016-03-31)
30,712 reads
A stored procedure from longtime community member Lowell Izaguirre, returns the CREATE TABLE definition for any table, including PK, UQ, Identity, FK, Defaults, and more.
2019-04-16
17,113 reads
Here a quick script showing how to get all the Active Directory users in a AD group.
2017-02-24 (first published: 2016-03-17)
8,762 reads
Changing Database Collation Through Primary keys, Foreign Keys, Default and Check Constraints and more.
2016-03-07
4,254 reads
2014-08-13
2,023 reads
How to reverse engineer or script a trace for disaster recovery, or simply scripting for enhance and adjustment.
2010-03-23
2,050 reads
a stored procedure returning a single varchar(8000) of the CREATE TABLE script for any table.It does everything calculated columns, rules,indexes,defaults,triggers,constraints...everything.
2009-07-28 (first published: 2009-07-11)
826 reads
returns CREATE TABLE script for any table. including schema name,calculated columns,
indexes with INCLUDE,rules,defaults,triggers,constraints,extended properties...everything.
2009-07-11
1,863 reads
Find And Replace any string, in the entire table with this function. Parameterized for easy use.
2009-02-26 (first published: 2009-02-09)
893 reads
The default trace keeps the last 20 meg of info, and a max of 5 files...This loads all 5 files into a table so it can be reviewed.
2009-02-25 (first published: 2009-02-07)
1,253 reads
Good documentation gets you started. Good books get you deep. After years of working...
By Vinay Thakur
In previous posts, we looked at the SQL Server engine. for us DBAs, the...
By Arun Sirpal
You have used Claude. But which Claude? The Claude app (claude.ai, the desktop and...
Comments posted to this topic are about the item Creating a JSON Document IV
By VishnuGupthanSQLPowershellDBA
Comments posted to this topic are about the item Restoring Azure Key Vault Keys...
When the schema of an object is changed, SQL Server wipes out the previous...
I have this data in a table called dbo.NFLTeams
TeamID TeamName City YearEstablished ------ -------- ---- --------------- 1 Cowboys Dallas 1960 2 Eagles Philadelphia 1933 3 Packers Green Bay 1919 4 Chiefs Kansas City 1960 5 49ers San Francisco 1946 6 Broncos Denver 1960 7 Seahawks Seattle 1976 8 Patriots New England 1960If I run this code, how many rows are returned?
SELECT YearEstablished, json_objectagg(city : TeamName) FROM dbo.NFLTeams GROUP BY YearEstablished;See possible answers