Archive for November, 2011

Declare @emps varchar(1000)
select @emps = COALESCE(@emps, ”) + ‘,’ + CAST(eid as varchar) from employee where firstname like ‘%vj%’
select ISNULL(substring(@emps,2,len(@emps)-1),”) Emps

Similar post …

NHibernate – ORM Tool

Posted: November 19, 2011 in NHibernate
Tags: ,

Documentation …

Quickstart Sample (Nice article)  –

Other links …





Use Windows Grep is to search the contents of one or more files on your PC for occurrences of text strings you specify and display the results. Once found, it can replace matches with other strings.




  • SQL Server 2012 code name Data Explorer and former Code Name – SQL Server Denali CTP3
  • Power View formerly Project Crescent – Browser based reporting tool (support on mobile devices)
  • Design environment / Visualization – Table – Convert it to card
  • SQL Server Data Tools formerly Juneau
  • Master Data Services (MDS)
  • Data Quality Services (DQS) Server/Client – SSIS can get data quality services benefit through Data Correction component and MDS can data quality service through MDS data quality functionality.
  • StreamInsight
References … – Microsoft SQL Server Code-Named “Denali” CTP3 Release Notes

In IE/Firefox we can use window.showModalDialog to show modal popup window. 
Use window.returnValue in the popup window to pass the selections to parent window.
Main Page Code ...
<script type="text/javascript">
    function ModalPopup() {
        var retValue = window.showModalDialog('popup.htm', 'height=200,width=150');
    <a href="#" onclick='javascript:ModalPopup()'>Click</a>
Popup Window Code ...
        function dosubmit() {
            window.returnValue = document.getElementById("txtName").value;
    <a href='#' onclick='javascript:dosubmit()'>Close</a>
    <input value="hi" type="text" id="txtName" />
But this showModalDialog has disadvantages like it will not work in Chrome and some other browsers and also test automation of UI using Selenium software will not.
Refer the below links for solution on Selenium issue ...
SELECT name, create_date, modify_date, type_desc FROM sys.objects 
WHERE type in ('P', 'V', 'U', 'FN', 'SN', 'TF', 'TR', 'TT') 
order by modify_date desc 

AF = Aggregate function (CLR)
C = CHECK constraint
D = DEFAULT (constraint or stand-alone)
F = FOREIGN KEY constraint
FN = SQL scalar function
FS = Assembly (CLR) scalar-function
FT = Assembly (CLR) table-valued function
IF = SQL inline table-valued function
IT = Internal table
P = SQL Stored Procedure
PC = Assembly (CLR) stored-procedure
PG = Plan guide
PK = PRIMARY KEY constraint
R = Rule (old-style, stand-alone)
RF = Replication-filter-procedure
S = System base table
SN = Synonym
SQ = Service queue
TA = Assembly (CLR) DML trigger
TF = SQL table-valued-function
TR = SQL DML trigger
TT = Table type
U = Table (user-defined)
UQ = UNIQUE constraint
V = View
X = Extended stored procedure