More: http://www.bbc.co.uk/news/technology-25000753
I'm a SQL Server Database Administrator. I post SQL related tips, information and help but also topics that interest me. I hope you find some of the postings interesting.
Sunday, 8 December 2013
Singularity University plots hi-tech future for humans
More: http://www.bbc.co.uk/news/technology-25000753
Saturday, 30 November 2013
SQL Performance Tuning tips
SQL Clustered and Non Clustered indexes
Clustered
Non Clustered
Friday, 29 November 2013
SSRS create linked report
What if more than one dept wants access to the same report?
SSRS can become quite crowded as reports are added. Creating folders for departments can help organise and group reports for business use. Then setting get up security for each folder to restrict users if that's how the business operates.
Creating a linked report from the source report is straight forward and allows groups of users to utilise the report from different folders. When on the web site for your reports, Manage the report and go to Properties the click Create Linked Report. Follow the simple instructions to place the linked report into a target folder.
Thursday, 28 November 2013
SQL 2008 R2 Agent Job properties.
The Description window in job properties is not overly text rich, like notepad you can't format text which is fine because this purely for brief information on what the job does etc.
The one thing I found really useful is using the keyboard shortcut CTRL - ENTER. This adds a carriage return and creates a new line for text, nice.
Wednesday, 27 November 2013
SQL Unions with If Statements
I discovered today that you cannot do a UNION in conjunction with If Statements in a SELECT.
If you know different please post it HERE!
Sunday, 24 November 2013
Best Practices for Virtualising and Managing SQL Server 2012
Introduction
This guide provides high-level best practices and considerations for deploying and managing MicrosoftSQL Server 2012 on a Microsoft virtualization infrastructure. The recommendations and guidance in this
document aim to:
Complement the architectural design of an organization’s specific environment.
Help organizations take advantage of the key platform features in SQL Server 2012 to deliver the
highest levels of performance and availability.
Executive Summary
With the proliferation of applications in everyday use, enterprises have an increasing need for moreinstances of databases such as SQL Server. Most applications have their own set of database
requirements, leading to the use of multiple versions of databases and to significant costs related to the
databases and related hardware resources. More importantly, the hardware deployed for databases is not
fully utilized or there is a demand to scale up hardware resources to meet peak utilization on certain
databases. Therefore, it has become important to control the cost of databases and related hardware
resources, and to optimize and scale the use of hardware resources in different scenarios to provide better
flexibility and maintain service level agreements (SLAs). An ideal solution to this problem is virtualization.
Virtualization is fairly common now. Many organizations worldwide have moved beyond the nascent
stage into being more advanced users of server virtualization, specifically. These organizations have
gained benefits in the areas of costs, efficiency, operations, availability, agility, and resiliency.
Microsoft SQL Server 2012 and Windows Server 2012 provide a host of new features that can be used to
effectively virtualize demanding database workloads that previously were not considered for virtualization.
This guide explains these new features in the context of how organizations should consider virtualizing
SQL Server 2012 on Windows Server 2012 and the benefits of managing this virtualized environment with
Microsoft System Center 2012. Working together, these industry-leading products deliver an integrated
platform with a low total cost of ownership (TCO) as well as mission-critical scale, performance, and
availability. The platform also provides enhanced end-to-end security, management, and monitoring
capabilities.
Further, many organizations now want to go a step beyond and adopt an IT infrastructure that is
optimized for and ready to work in the cloud. They need an IT infrastructure that can seamlessly span
from a private to a public cloud. To achieve this goal, organizations require a common virtualization
platform that can increase performance and efficiency across the infrastructure. In this regard, Windows
Server 2012 Hyper-V offers an ideal virtualization platform for SQL Server 2012.
SQL Server Database documentation
ApexSQL Doc
I use this product and it's pretty good. It struggles sometimes with dealing with multiple servers but you can break those down to more manageable jobs so that it does not error during processing. On the whole, its a great piece of software which describes and documents your databases using the extended properties as the descriptors.
Tip: It's a very good idea when using SQL Server Extended Properties to decide what you are going to use use as a label i.e. 'MS_Description' and then use this label all the way through your descriptions for Tables, Fields etc. The reason for this is that Apex SQL Doc can only use one label so if you have different labels sprinkled throughout your database you won't see them all when you carry out your database documentation.
Your database Visualised. Database to documentation in a variety of formats.
Generate database and SSIS documentation in CHM, HTML and Word
Automate and schedule the documenting process
Include relationship diagrams in your database documentation
Leverage extended properties and edit them directly
More information: http://www.apexsql.com/sql_tools_doc.aspx
SQL Prompt - Write, refactor, and explore SQL effortlessly
Real world positive feedback from the T-SQL coal face
I have been using this tool for a few years now and can tell you it saves me a lot of time from re-writing T-SQL. I also love the new History tab so all those SSMS Queries you closed down thinking you didn't need them and then discover in fact you did? Well the history tab remebers what you typed and allows you to reteive your work, no more lost work!
The SQL Format function is brilliant, no more messy code!
Enjoy!!
5 ways coding becomes effortless with SQL Prompt:
NEW! Tab history - save, search, and recover tabs in SSMSIntelliSense-style code completion
Customizable code formatting
Save code snippets
Refactor SQL code
SQL Prompt is an add-in for SQL Server Management Studio and Visual Studio, and has been designed to strip away the repetition of coding.
More information: http://www.red-gate.com/products/sql-development/sql-prompt/
SQL Assistant - for SQL Server, SQL Azure, Oracle, DB2, Sybase, MS Access, PostgreSQL, and MySQL
The ultimate tool for database development
SQL Assistant equips database developers and DBAs with the productivity tools they need to speed up the database development process, improve code quality and accuracy. SQL Assistant can boost your SQL coding productivity by 300%. SQL Assistant supports all major databases. It is shipped pre-configured with support for Oracle, Microsoft SQL Server, IBM DB2, MySQL, PostgreSQL, Sybase ASE and SQL Anywhere. The product also offers a full-featured source control interface that supports the Subversion and Microsoft Team Foundation Server code repositories. Many users have stated they don't know how they can code and manage their databases without SQL Assistant. To get a better idea of what it can do for you, download the trial and check it for yourself.
More information: http://www.softtreetech.com/isql.htm
Most Terrifying Hikes In The World
250 Hard Drives Used To Make One Awesome F1 Car
Saturday, 23 November 2013
Open data
Wikipedia list of countries that offer open data.
http://en.wikipedia.org/wiki/Open_dataWhat is Open Data?
Open data is the idea that certain data should be freely available to everyone to use and republish as they wish, without restrictions from copyright, patents or other mechanisms of control. The goals of the open data movement are similar to those of other "Open" movements such as open source, open hardware, open content, and open access. The philosophy behind open data has been long established (for example in the Mertonian tradition of science), but the term "open data" itself is recent, gaining popularity with the rise of the Internet and World Wide Web and, especially, with the launch of open-data government initiatives such as Data.gov and Data.gov.uk.Raspberry Pi hack creates a smart TV
China's 'Sharp Sword' stealth drone makes maiden flight
Friday, 22 November 2013
Men robbed and knocked unconscious for Xbox One consoles
What core skills should someone have with T-SQL?
I'll start the list, but feel free to add to it or give me your thoughts. I think someone ought to be able to understand these items and write code to solve problems that involve:
finding duplicate rows (grouping, joins)
returning aggregates of single or multiple columns (MAX, MIN, SUM, COUNT)
return aggregates in groups, or islands. (grouping and aggregates, windowing)
join multiple tables together on matching, multiple columns (joins)
find data in one table that doesn't have matches in another (outer joins)
filtering data (WHERE) subqueries and complex CTE joins of data
create row numbers and join back to a table without numbers (APPLY)
pivoting data from rows to columns
Wednesday, 20 November 2013
Wolfram|Alpha - Computational knowledge engine
Wolfram|Alpha introduces a fundamentally new way to get knowledge and answers - not by searching the web, but by doing dynamic computations based on a vast collection of built-in data, algorithms, and methods.
Google Public Data Explorer
The Google Public Data Explorer makes large, public-interest datasets easy to explore, visualize and communicate. As the charts and maps animate over time, the changes in the world become easier to understand. You don't have to be a data expert to navigate between different views, make your own comparisons, and share your findings.
SQL Injection can destroy your database
An SQL Injection can destroy your database. Read this chapter from http://www.w3schools.com/ which explains the 'how', having this knowledge will enable you to prevent SQL Injection.
SQL Monitor
http://www.red-gate.com/products/dba/sql-monitor/