Concetenate the two fields and display the records with comma separated string in one field.SELECT p_scrid,SUBSTRING(( SELECT (' ,' + screen_name) FROM tbl_SCRMst t2 WHERE t1.p_scrid = t2.p_scrid ORDER BY p_scrid, screen_name FOR XML PATH( '') ),3,1000)FROM tbl_SCRMst t1GROUP BY p_scridThanks & Reg...
Friday, April 30, 2010
Saturday, April 3, 2010
Check record exist or not using asp.net and c#
This code show how to check record exist in database.Method get custid as a parameter and pass to stored procedure that will check record exist or not.public bool IsCustomerExist(string strCust){ //SqlConnection objSqlConnection = null; SqlCommand objSqlCommand = null; try { //objSqlConnection = new SqlConnection(ConfigurationManager.ConnectionStrings["StrConnect"].ToString());...