Dennes Torres

Dennes Torres is a Data Platform MVP and Software Architect living in Malta who loves SQL Server and software development and has more than 20 years of experience. Dennes can improve Data Platform Architectures and transform data in knowledge. He moved to Malta after more than 10 years leading devSQL PASS Chapter in Rio de Janeiro and now is a member of the leadership team of MMDPUG PASS Chapter in Malta organizing meetings, events, and webcasts about SQL Server. He is an MCT, MCSE in Data Platforms and BI, with more titles in software development. You can get in touch on his blog https://dennestorres.com or at his work https://dtowersoftware.com

Follow Dennes Torres via

20 June 2017
20 June 2017

Visual Studio 2017 and Swagger: Building and Documenting Web APIs

The OpenAPI ‘Swagger’ Specification defines a protocol that allows applications to discover, and generate documentation of methods, parameters and models of REST APIs, This provides a way for any software to identify the features of a REST API. It does for REST APIs what WSDL (Web Service Description Language) did for web services. Visual Studio now provides it to support proxy creation for REST APIs, as Dennes Torres explains.… Read more
20 June 2017
20 June 2017

SQL 2017 new DMF: Managing VLOGs in our databases

SQL Server 2017 brings to us some new interesting DMV’s and DMF’s, one of them is sys.dm_db_log_info. This new DMF allows us to manage VLOGs in our databases. The log files are divided in smaller slices called virtual log files, or vlog. Operations such as log truncations happens over an entire vlog. For example, when … Read more
09 June 2017
09 June 2017

Filtering Errors in PowerBI

I just faced this problem when trying to analyze some information from google analytics in PowerBI. In my specific situation, I was trying to extract a number from some URL querystrings and filter the rows without the number. When I set the data type of the column to decimal, the rows without a number receive … Read more
06 June 2017
06 June 2017

Query Store and Parameterization Problems

The query store gives us a novel way of identifying those queries that are causing performance problems when they are parameterized by SQL Server for reuse. Although it is relatively simple to ensure that certain troublesome queries avoid the problem, it is laborious to identify these queries. Additionally, Query Store gives us the means to fix the problem for groups of queries by means of plan guides without changing the DDL at all. Dennes Torres explains the details… Read more
02 June 2017
02 June 2017

News for Differential Backup

SQL Server 2017 brings several improvements to us. Sometimes a simple new field in a DMV can turn possible interesting new functionalities. That’s what happens with differential backup in SQL Server 2017. The DMV sys.dm_db_file_space_usage has a new field: modified_extent_page_count . This new field tell us how many pages were changed since the last full backup. … Read more
27 December 2016
27 December 2016

How to allow nulls in unique fields

An interesting workaround using unique fields Unique fields in SQL Server are created using unique constraints or unique indexes, furthermore, each unique constraint uses a unique index. Regardless of using unique constraint or unique index, the field can accept null values, however the uniqueness will result in only accepting a single row with null value. The solution … Read more
16 September 2016
16 September 2016

Careful With Trustworthy Setting

Trustworthy database setting is an easy solution for some problems in the server, especially cross database access. However, this setting has also a security problem in some scenarios. The scenario that has a security break is the following: One or more databases are owned by a user with ‘sysadmin’ rights. If the databases were created … Read more
31 August 2016
31 August 2016

Creating schemas without DBO permission

One result of having the correct care with the access permissions in our databases is the need to avoid the DBO permission even to the users responsible for the database model. Using the database roles such as ddl_admin or even in more grainy ways it’s easy to achieve this goal. However, it’s more complex when … Read more
23 May 2016
23 May 2016

Identifying client timeouts

Long running queries often causes client timeout in our applications. One good solution to attack this problem is to identify the timeouts and optimize the queries causing the timeouts. Client timeouts or connection interruptions are identified as Attention events. We can capture the attention events using an Extended Events session. The script to create the … Read more
09 May 2016
09 May 2016

How to identify contention in TempDb

TempDb database is used to store all temp tables created for our applications. Whether explicit or implicit created, all temp tables activity is done in tempdb, creating a bottleneck. For this reason, it’s important to identify tempdb contention. Tempdb contention will appear in the form of latches. Latch is a synchronization object that protects internal … Read more
02 May 2016
02 May 2016

How to find blocked processes

Blocked processes are often a big problem to DBA’s. They are difficult to monitor. We receive desperate calls saying “Everything is slow!” and before we can do anything a second call “Oh, don’t worry, it’s everything ok again”. Most of times it happens because ill-behaved process that blocks other tasks for short periods. How can … Read more
27 April 2016
27 April 2016

Are the statistics being updated?

The auto-update statistics configuration updates statistics when the amount of row changes in the table achieves 20% of total rows. However, for tables with too many rows, this threshold is too high. For example, a table with 1 million rows will only update statistics after 200 thousands changes. That’s too much and can affect query … Read more
19 April 2016
19 April 2016

How to find CPU intensive queries

High CPU usage is a very common problem in SQL Servers. Any query with a bad query plan can steal CPU time and harm system response time. Fortunately we can find queries with high CPU time using sys.dm_exec_query_stats DMV. This DMV, created in SQL Server 2008, keeps performance statistics for cached query plans, allowing us … Read more
15 March 2016
15 March 2016

Creating a Date Dimension in a Tabular Model

0
As well as its multidimensional model, SQL Server Analysis Services (SSAS) now has a tabular model of database that either runs in-memory or in DirectQuery mode. The in-memory analytics engine allows the users of Excel or Power View to base reports on tabular model objects. Having shown how to handle date-based information using the Multi-dimensional model, Dennes now turns his attention on the in-memory tabular model.… Read more
0
25 February 2016
25 February 2016

How to find blocked process

Blocked processes are often a big problem to DBA’s. They are difficult to monitor. We receive desperate calls saying “Everything is slow!” and before we can do anything a second call “Oh, don’t worry, it’s everything ok again”. Most of times it happens because ill-behaved process that blocks other tasks for short periods. How to … Read more
16 February 2016
16 February 2016

How to find CPU intensive queries

High CPU usage is a very common problem in SQL Servers. Any query with a bad query plan can steal CPU time and harm system response time. Fortunately we can find queries with high CPU time using sys.dm_exec_query_stats DMV. This DMV, created in SQL Server 2008, keeps performance statistics for cached query plans, allowing us … Read more
24 January 2016
24 January 2016

Are your check constraints trustable ?

SQL Server keeps a record to identify if a check constraint is trustable or not. When all the records in the database where checked against the constraint it’s trustable, otherwise it’s not. If the check constraint is trustable, it can be used by the query optimizer. For example, if the check constraint avoid values below … Read more