I want some Moore

Blog about stuff and things and stuff. Mostly about SQL server and .Net
posts - 218, comments - 2281, trackbacks - 33

My Links

Advertisement

News

Hi! My name is 
Mladen Prajdić  I'm from Slovenia and I'm currently working as a .Net (C#) and SQL Server developer.

I also speak at local user group meetings and conferences like SQLBits and NT Conference
Welcome to my blog.
SQL Server MVP

My Books

SQL Server MVP Deep Dives 2
The Red Gate Guide to SQL Server Team based Development Free e-book

My Blog Feed via Email
Follow MladenPrajdic on Twitter


Users Online: who's online

Article Categories

Archives

Post Categories

Cool software

Other Blogs

Other stuff

SQL stuff

December 2006 Blog Posts

CRUD stored procedures generating SSMS Add-in

UPDATE:  This is now a part of a larger SSMS Add-In called SSMS Tools Pack I thought I'd post something special as the last post of this year and i was thinking about what it would be. Fellow SqlTeamer Rockmoose said he'd like to have an add-in for SSMS that would genereate basic CRUD (Create - Insert, Read - Select, Update, Delete) stored procedures for a table. And he'd like to have it on the context (right-mouse-click) menu of the table in Object Explorer in SSMS.   It sounded like a very cool little project and with the help of this excellent post about SSMS add-ins I've decided to...

posted @ Thursday, December 28, 2006 11:10 PM | Feedback (40) | Filed Under [ SQL Server SSMS Tools Pack ]

Extending DateTime to include dates less than 1753-01-01 in SQL Server 2005 with CLR UDT

I was playing with some historical data (family tree) and i wanted to store data in sql server. When looking into family trees you reach the minimum datetime value of 1753-01-01 very soon. But .Net can save dates from 1.1.0001 on. So i went looking into using SQL CLR user defined datatype (UDT). UDT's are interesting because you have to serialize them. There are 3 ways of doing that:  - Format.Native  - Format.UserDefined   - Format.Unknown When Format.Native is used you can only use blittable datatypes. Bol says these are: bool, byte, sbyte, short, ushort, int, uint, long, ulong, float, double, SqlByte, SqlInt16, SqlInt32, SqlInt64, SqlDateTime,...

posted @ Saturday, December 16, 2006 10:11 PM | Feedback (8) | Filed Under [ .Net SQL Server ]

When are SQL Server schema objects Case Senstive?

I've come across an interesting thing today that i didn't even think could be an issue: Case senstive object names (tables, columns, triggers, views, etc....). If your database is created with a Case Sensitive collation then all object names will be Case Sensitive. I always thought that collations are used for data and not schema but i guess i was wrong. We had an issue with a view that had a lower case column name in it when it should be uppercase.   A bit of code to prove it:create database testCollation collate Latin1_General_CS_AS -- case sensitive collation go use testCollation create table Test(Col1 int, col2 int) insert into...

posted @ Thursday, December 07, 2006 2:05 PM | Feedback (7) | Filed Under [ SQL Server ]

When (int)x isn't the same as Convert.ToInt32(x)

Having started programming in c/c++ i've always been used to casting between types using () operator: int i = (int)x With the coming of .Net framework ValueTypes and ReferenceTypes were introduced and we started hearing about boxing and unboxing. if you're not familiar with these terms pick a link from this search and read up. Also we've been introduced to System.Convert class and IConvertible interface.   But old habits are hard to break and i've been preffering the (int) to Convert.ToInt32. For all thing considered i've been treating them as equals. But i've been reminded that they're not with a nice little error...

posted @ Monday, December 04, 2006 10:35 AM | Feedback (8) |

Multi Connection High precision time measuring in SQL Server 2005

In a previous post I've shown how to use High precision timer. That method had a drawback of working for whole server not distiguishing between connections. So if you ran the time measurement in 2 different windows in SSMS the times would be incorrect. You'd get the correct time in the window which was run last. This of course isn't very usefull for proper performace diagnosys. So with little experimenting i've managed to fix the timer to work properly for each connection. The code is self explanatory. For each function run I return the spid to which it belongs and i store the HiPerfTimer objects in a...

posted @ Saturday, December 02, 2006 9:46 PM | Feedback (0) | Filed Under [ .Net SQL Server ]

PFDavAdmin Tool - Exchange 2000 and 2003 DAV-based Administration Tool

Lately i've been doing quite an amount of work with Exchange and WebDAV access to it. Documentation on WebDAV and Exchange server is ok for simple tasks but if you want anything concrete done examples are impossible to come by. That's  why I posted a lengthy article about WebDAV and my experience with it. Two tools are indespensible when doing any kind of Exchange access development: Outlook Spy and Exchange Explorer that comes with the Exchange SDK.   But neither of those help in any way with forming correct WebDAV XML requests. OK, they give you the name and namespace of the properites but that's it. Well PFDavAdmin Tool to...

posted @ Saturday, December 02, 2006 6:50 PM | Feedback (0) | Filed Under [ Exchange ]

Powered by:
Powered By Subtext Powered By ASP.NET