A community of more than 1,600,000 database professionals and growing
The Voice of the DBA
Your Frame of Reference
Is a database snapshot in SQL Server update-able? Most of us would say no, but I ran across a blog from the Microsoft SQLCAT team that proposes a method of issuing an insert, update, or delete statement in a database snapshot context. You can read the article for the details, and we could argue if this is really allowing a snapshot to be read/write, but that's not what I noticed as I read this.
This is a very creative way of approaching a problem. It changes the frame of reference slightly so that we rethink what the customer is trying to accomplish instead of what the technology limitations are. There might be more elegant, or more easily maintained solutions, but I found this to be creative, and perhaps useful, approach for solving a certain domain of problems.
I think quite often we get caught in viewing problems in terms of our frame of reference, or in terms of common technology implentations without thinking through the problem from the customer's frame of reference and working on an effective solution. That's our job most of the time: being effective as we solve problems. If we view all problems within the narrow range of our past solutions, we are relying on our experience, but that may prevent us from building applications that work better than our past work, go beyond what our customers want and get them excited about using the end result.
However it's a balance. I've seen hacked solutions that didn't perform well, or didn't scale and ended up causing problems for years. Looking at the problem from the customer's viewpoint needs to be tempered with the requirement of building a solution that performs well and fits within the framework of the environment. Ultimately I think the way to get better at building applications (and databases) is to increase your knowledge and experience. Learn more about other people's solutions, and engage with the rest of the community to sanity check your approach. Learning new techniques that have worked for others, and experimenting in your environment to build better software over time.
The continuing drop in the price of memory has made fast in-memory OLTP increasingly viable. SQL Server 2014 allows you to migrate the most-used tables in an existing database to memory-optimized 'Hekaton' technology, but how you balance between disk tables and in-memory tables for optimum performance requires judgement and experiment. More »
This metric returns the number of check constraints that have their is_not_trusted flag set to 1 in the sys.check_constraints table. Untrusted constraints force SQL Server to construct less efficient query plans, because it doesn’t know enough about the kind of data contained in the table. This can point to a data integrity issue which should be investigated. More »
When a SQL Server database is operating smoothly and performing well, there is no need to be particularly aware of the transaction log, beyond ensuring that every database has an appropriate backup regime and restore plan in place. When things go wrong, however, a DBA's reputation depends on a deeper understanding of the transaction log, both what it does, and how it works. An effective response to a crisis requires rapid decisions based on understanding its role in ensuring data integrity.
SQL Server 2012 T-SQL Recipes is an example-based guide to the Transact-SQL language that is at the core of SQL Server 2012. It provides ready-to-implement solutions to common programming and database administration tasks. Learn to create databases, insert and update data, generate reports, secure your data, and more. Tasks and their solutions are broken down into a problem/solution format that is quick and easy to read so that you can get the job done fast when the pressure is on. Get your copy from Amazon today.
Change @NewSMTP to a valid server name or IP address or leave NULL if you just want to generate the accounts as they are.
To skip the ping test, simply change @TestPing to 0.
If you have many accounts then it might be necessary to remove
@SQL = @SQL +
from the SELECT statement.
This will return each accounts TSQL in table format.
For SMTP authentication users, remember to change each users password before you run the generated script.
If there is only one account or only one password for multiple accounts then set the @PW variable.
How to make this block dynamic?
- I'm just not sure how to do it.
When I run:
select @liststr = coalesce(@liststr+',' ,'') + quotename(column_name)
from [server].j3688802s.information_schema.columns where table_name = 'sample'
I get a...
Auditing - no machine name? Really?
- I'm going through trialing out Auditing using this example:
What I can't understand though is that it doesn't store the source...
Different between two query
- Hi Dear,
What is different between two query?
FROM dbo.Person LEFT OUTER JOIN
dbo.CustomerSegment ON dbo.Person.CustomerSegment = dbo.CustomerSegment.Code INNER JOIN
- I have a need to update numeric values in a table column so that they are unique and sequencial, the...
.net csv Reader
- This library can read CSV files, including handling columns that have line feeds in them. It is inexpensive too.
This newsletter was sent to you because you signed up at SQLServerCentral.com.
Feel free to forward this to any colleagues that you think might be interested.
If you have received this email from a colleague, you can register to receive it here.