Exclusive access could not be obtained because the database is in use

About the Error Message: “Exclusive access could not be obtained because the database is in use” A very neat feature of SQL Server is the way it lets the DBA to control connections. To this end, you can explicitly control connections with specific commands and methods. Even though this is not usually needed, there are … Read more…

I am an INETA Country Leader

Today I have officially received the role of the INETA Country Leader for Cyprus.It was an honor for me to receive this role as it will allow me to further promote the .NET community activity in Cyprus. The main responsibility of this role is to supervise INETA User Groups in Cyprus and to promote technical … Read more…

Manipulating EXCEL 97-2003 Worksheets with the OPENROWSET Command

In this article, we will be discussing about manipulating EXCEL 97-2003 worksheets with the OPENROWSET command. About the OPENROWSET Command SQL Server provides among other the neat feature of the OPENROWSET command. OPENROWSET allows establishing ad hoc connections using OLE DB. It actually allows one-time access to remote data from an OLE DB data source. If … Read more…

A transport-level error has occurred when sending the request to the server

In this article, we will be discussing about the “A transport-level error has occurred when sending the request to the server” error message, you might get in SQL Server. This article’s purpose is to explain the above connectivity error and ways of resolving it.   Why you might get the “transport-level” error in SQL Server … Read more…

Leadership Award

Today we had our company presentation regarding the financial results of the year 2008. One of the sessions of this meeting were the Employee Awards for 2008. To my pleasant surprise I have received the Leadership Award for the year 2008 “in recognition of accomplishments far exceeding company expectations” and for gaining and applying technical … Read more…

Divide by zero error encountered

In this article, we will be discussing about the “Divide by zero error encountered” error message in SQL Server. About the “Divide by zero error encountered” error message Well, as the error message says, whenever we have a division within a SQL query and the denominator has the value of zero (0) we get this … Read more…

Introduction to ASP .NET AJAX

Well, another successful event took place yesterday in another one of our regular community events of the Cyprus .NET User Group.   About the Event This time the topic was ASP .NET AJAX. Our special guest speaker was Karl Davies-Barrett, Developer Platform Evangelist (Microsoft Malta/Cyprus). AJAX stands for Asynchronous JavaScript and XML. It allows the … Read more…

String or binary data would be truncated

There are many times where a query may result to the following error: String or binary data would be truncated. The statement has been terminated. We will go through a simple example for explaining this behavior.   Reproducing the “String or binary data would be truncated” error Creating the Sample Table Consider the following table: CREATE TABLE … Read more…

The Multi Part Identifier Could not be Bound

There are cases where a SQL Server database developer might get an error message similar to: “The multi part identifier could not be bound“. This happens because of the way the database developer handles table scopes within the query. Read the article below, in order to better understand this error, and see how easy is … Read more…

Microsoft SQL Server 2008 Feature Pack

SQL Server 2008 is undoubtedly an extremely powerful Relational Database Management System. It comes with many new features that increase the database developer’s productivity and make the life of the DBA easier. In September 2008, Microsoft has published the SQL Server 2008 Feature Pack, which includes various stand-alone install packages which provide additional value for … Read more…

Commonly used string functions in SQL Server

In this post, I provide a list of commonly used string functions in SQL Server.By combining these functions, it is possible to easily manipulate strings. — REPLICATE — This function given a string and an integer N, it repeats N-times the given string— Example:declare @string as varchar(10)declare @num_repeats as int set @string=’ABCD ‘set @num_repeats=4 select … Read more…

SQL Server 2005 Surface Area Configuration Tool

An important security improvement in Microsoft SQL Server 2005 is that various of its features that could be potentially susceptible to security risks are turned off by default. One of these features is that the built-in administrator of the machine on which SQL Server 2005 is installed, it is not automatically included in the SQL … Read more…

Getting table index information in SQL Server

At some time today, I had to compare the indices of various database tables.To this end, I needed a fast way of getting index information for specific tables. In SQL Server, there is a system stored procedure (hosted in the master database) called sp_helpindex. The syntax for using it is the following: EXEC sp_helpindex ‘schema.table_name’ … Read more…