AT TIME ZONE – a new favourite feature in SQL Server 2016
Rob Farley explains why AT TIME ZONE is his new favourite feature in SQL Server 2016, but also shows that it can make a mess of cardinality estimates.
2016-09-22
4,108 reads
Rob Farley explains why AT TIME ZONE is his new favourite feature in SQL Server 2016, but also shows that it can make a mess of cardinality estimates.
2016-09-22
4,108 reads
2016-09-21
125 reads
The SQL Server Error Log is quite large and it's not always easy to view the contents with the Log File Viewer. Greg Robidoux presents an easy way to search and find errors using T-SQL.
2016-09-20
5,284 reads
In-memory OLTP was introduced in SQL Server 2014, but greatly improved in SQL Server 2016. If you have a heavily-used transaction-processing that is processing a lot of data, it is definitely worth considering the new 'In-Memory' features of SQL Server 2016. Grant Fritchey explains why.
2016-09-19
5,042 reads
Foreign Keys are one of the fundamental characteristics of relational databases and enforce the referential integrity. Is it a good idea to index a FK relationship? When can it help?
2016-09-16 (first published: 2015-06-29)
15,783 reads
To demonstrate that dynamic modules in PowerShell can be used to easily create objects with methods and properties, Phil Factor implements an expression analyser written in PowerShell, using a variation of Dijstra's Shunting Algorithm.
2016-09-16
5,804 reads
Row Level Security is one of many new features in SQL Server 2016. It provides a much easier, consistent, and maintainable solution for row-based security rules. In this blog post, Data Platform MVP Steve Jones introduces this new feature, and walks through how Redgate SQL Compare can safely and reliably handle RLS changes.
2016-09-15
3,121 reads
Tim Smith shares some ideas about how to handle and alert on irregular data coming from APIs when loading your database.
2016-09-14
3,377 reads
Read about the Restore Genie and the new support for fork points, Azure and Multiple Concurrent Restores.
2016-09-13
1,943 reads
Power BI allows you to connect directly to the data just as if it were a “standard” connection, and modify and extend the data to support analytics. By using DirectQuery, you can build reports based on extremely large datasets where re-importing data not a practical solution. It also allows you to do data aggregations on the server. There are, of course, restrictions as well but it is nevertheless a worthwhile technique to use where appropriate. Adam Aspin explains all.
2016-09-13
4,392 reads
With Fabric Mirroring, Microsoft is promoting a nice and appealing story for operational reporting...
If you’ve been watching AI roll through the data community and thinking, “this seems...
By Arun Sirpal
Not every production incident is a database in RECOVERY_PENDING or a corrupted event (like...
Comments posted to this topic are about the item SQL Art, Part 4: Happy...
Hi All I am trying to find 'bad' characters that users might type in....
Comments posted to this topic are about the item Extreme DAX: Take your Power...
I set up a few users on my SQL Server 2022 instance.
CREATE LOGIN User1 WITH PASSWORD = 'Demo12#1' CREATE USER User1 FOR LOGIN User1 GO CREATE LOGIN User2 WITH PASSWORD = 'Demo12#2' CREATE USER User2 FOR LOGIN User2 GO CREATE LOGIN User3 WITH PASSWORD = 'Demo12#3' CREATE USER User3 FOR LOGIN User3 GOI then created a schema that one of them owned. Under this schema, I added a table with some data.
CREATE SCHEMA MySchema AUTHORIZATION User1
GO
CREATE TABLE Myschema.MyTable(myid INT)
GO
INSERT MySchema.MyTable
(
myid
)
VALUES
(1), (2), (3)
GO
SELECT * FROM MySchema.MyTable
GO
I granted rights and verified that User2 could access this table.
GRANT SELECT ON Myschema.MyTable TO User2 GO SETUSER 'USER2' GO SELECT * FROM MySchema.MyTable GOThis worked. Now, I move this schema to a new user.
ALTER AUTHORIZATION ON SCHEMA::Myschema TO User3; GOWhat happens with this code?
SETUSER 'USER2' GO SELECT * FROM MySchema.MyTable GOSee possible answers