Subscribe to SQLTeam.com

Weekly SQL Server newsletter with articles, forum posts, and blog posts via email:

SQLTeam.com Articles via RSS

SQLTeam.com Weblog via RSS

- Advertisement -

- Sponsor's Message -

SQLShare.com Videos

Writing to the Registry from TSQL Using XP_Instance_RegWrite

Reading from the registry to figure out a configuration issue or two is common, but writing to the registry isn't something you'll need to do very often. Still, it's a useful trick to know and we've put it to work showing you how to alter the default folder used for database backups.

Using XP_Instance_RegRead To Get Default Database Path

SQL saves more than a few things to the registry and we can leverage that by reading those settings from TSQL using xp_instance_regread. Easy to use and only one minor quirk to learn, and you'll reading from the registry. Look for the follow up video that demonstrates how to write changes to the registry too.

How to Change the Default Path for New Databases

Typing CREATE DATABASE MyDB gets the job done, but it puts the files in whatever location has been set as the default - which means you should make sure the default is set to a good place, or specify them as part of the CREATE. We'll show you how to adjust the setting (and we've got a video coming up that shows you how to change it from code too!).

Overview of Data Driven Subscriptions in Reporting Services

Subscriptions are a powerful feature of Reporting Services because they allow users to decide which reports to receive. But what do you do when the boss wants a report sent to a group of users, perhaps based on some additional criteria that frequently changes? That's where data driven subscriptions make sense and in our lesson today Devin does a nice overview of the options and requirements.

Using DatePart and DateName

Ever want to get the month out of a date as a number, or as literal text? Many people will do it by parsing the date as a string, but we've got some built in functions that will do it cleanly and consistently.