Partitioning in SQL Server - Part 2
Arshad Ali examines the different concepts of partitioning in SQL Server 2012 and provides a step-by-step guide on creating a partition table/index.
Arshad Ali examines the different concepts of partitioning in SQL Server 2012 and provides a step-by-step guide on creating a partition table/index.
Make the ad-hoc analysis of identifying potentially double-counted or sign-reversed Accounting transactions simple and painless.
The average value of a lost laptop has been found to be much more than you might expect. Steve Jones talks about a recent study.
Louis Davidson explains why DBAs often need a healthy dose of selective, enforced amnesia about the pain of previous failures.
It is frustrating when you hit 'submit' and you get the hourglass big-time. Is it the database to blame? It could be, but there are other suspects that should be considered. Feodor Georgiev describes where, in the long route, to and fro', that a data request makes before returning, that things can get snarled up.
This week Steve Jones asks how you might handle DR preparation or process differently in the new year.
It should be easy to model a game of poker in SQL. The problem is, however, that you need to model a permutation from a set of elements. Joe Celko argues that using a group of columns to do this isn't necessarily a violation of 1NF, since a permutation is atomic. Then comes the second problem: how would you sort such a column-base permutation in order? Sorting columns in SQL?
Should you think about using SSD storage in your SQL Server databases? Steve Jones thinks this might be something you should consider.
Partitioning has improved with each new version of SQL Server. From partitioned views in SQL Server 7.0 through partition table parallelism in SQL Server 2008. With SQL Server 2012, we are now allowed to even create up to a 15K partition on a single table.
Often times we are tasked with having to programmatically come with a list of durations per SQL Server Agent Job to trend the run times and order the results by date. Unfortunately it's not always easy in the way the data is stored in the system tables in the MSDB database. This tip explains how to use the system tables to get the data into the correct format for dates and job durations.
It is Friday, the queries are running, and nobody is watching the bill. That...
By Steve Jones
Annabel retired from Redgate Software this week. Across most of my career at Redgate,...
By Tim Radney
As a SQL Server DBA with years of experience tuning production environments, I’ve seen...
Comments posted to this topic are about the item What is the Cloud?
Comments posted to this topic are about the item Changing the Schema
Comments posted to this topic are about the item Index Fragmentation Explained: Page Splits,...
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