How to store UTF-8 data in SQL Server

Category: IT, MS SQL Server, PHP Tags: , , , , , Comments: 2

Very frequently we need to use the data type UTF-8 to store a data in different languages. As described in the MSDN page the UTF-8 data type is stored in the ‘Samples’ folder in SQL Server (Server\100\Samples\Engine\Programmability\CLR\UTF8String). You just need to activate it.

MaraK

Category: C#, IT, MS SQL Server Tags: , Comments: 3

I’m starting a project for management of a small store, using C# and SQL Server Express.
Félicitations

SELECT * or SELECT [Column Name] in IF statement in MS SQL Server

Category: IT, MS SQL Server, Transact-SQL Tags: , , Comments: 1

When we decide how to manipulate the data, we use IF statement verification. For example if we export information about merchant sales, we have two common groups of merchants – these we scan (with serial numbers) and these we don’t scan. For both of them we use two BEGIN… END blocks. To verify the type [...]

Select server logins and their roles in SQL Server

Category: IT, MS SQL Server Tags: , , Comments: 0

To view all the server logins and their roles I use the system view sys.syslogins and CASE to convert 1 to “Yes” and 0 to “No”.

Filegroups and Autogrowth in MS SQL Server

Category: IT, MS SQL Server Tags: , , Comments: 0

Yesterday I was asked about the way a table is stored in several files in a filegroup.

DENSE_RANK() function in MS SQL Server

Category: IT, MS SQL Server, Transact-SQL Tags: , , , Comments: 0

As we can read in Books Online in SQL Server
Ranking functions return a ranking value for each row in a partition. Depending on the function that is used, some rows might receive the same value as other rows. Ranking functions are nondeterministic.
I have created simple example for usage of the Ranking function DENSE_RANK().

Simple SSIS Project – export to flat file, FTP upload, archive (create the package)

Category: IT, MS SQL Server Tags: Comments: 4

Microsoft® SQL Server™ Integration Services is the tool that connects the database to the world and works instead of us. I’ll show you how to extract simple data from the database, store the files in a the file system, rename them, upload them on FTP and report the errors to administrator if any.

The difference between WHERE and HAVING filters in SQL Server

Category: IT, MS SQL Server, Transact-SQL Tags: , Comments: 0

The difference between WHERE and HAVING filters in Transact-SQL queries is that WHERE clause is a filter of all the data, while HAVING filters the GROUP BY data. I’ve prepared a simple example.

MS SQL Server Cursor Example

Category: IT, MS SQL Server Tags: , Comments: 1

The cursors in MS SQL Server are not the best way to manipulate the data, because they need more recourse. If you can escape the usage of cursors, do it. OK, the cursors give us a flexible way of manipulating the information. You can imagine a bundle of information, that we use for move through [...]

Generate filename (Name_Date_Time.txt) for a report with Transact-SQL in Microsoft SQL Server

Category: IT, MS SQL Server Tags: , Comments: 0

My ex-colleague asked me how to insert query result in a variable for generate report in Microsoft SQL Server. After few explanations I noticed that she has decided to use SSIS (SQL Server Integration Services) to automate. She sent me an example in which she uses YEAR(), MONTH() and DAY() functions.


Page 1 of 212