<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-4398024747633199956</id><updated>2011-04-21T14:13:43.565-07:00</updated><category term='Exception Handling Application Block&apos;s Exceptions'/><category term='DataGrid'/><category term='Query String'/><category term='Check box'/><category term='CSS'/><category term='Javascript'/><category term='Errors'/><category term='HTML'/><category term='Custom Publisher'/><title type='text'>Sandy Zone</title><subtitle type='html'>The latest in Microsoft technologies</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>24</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-2939478254361929892</id><published>2009-02-19T03:10:00.000-08:00</published><updated>2009-02-19T03:11:20.907-08:00</updated><title type='text'>EXEC SP_XML_PREPAREDOCUMENT</title><content type='html'>PREPARE XML DOCUMENT&lt;br /&gt;&lt;br /&gt;While handling using bulk inserts / updates ( using XMl in Stored Procedures )&lt;br /&gt;care must be taken to handle to below characters.&lt;br /&gt;&lt;br /&gt;1. &amp;&lt;br /&gt;2. &lt;&lt;br /&gt;3. &gt;&lt;br /&gt;4. '&lt;br /&gt;5. "&lt;br /&gt;&lt;br /&gt;XMl cannot process these symbols.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;We need to pass them as html codes so that they get inserted properly.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;1. &amp;amp;&lt;br /&gt;2. &amp;lt;&lt;br /&gt;3. &amp;gt;&lt;br /&gt;4. &amp;quot;&lt;br /&gt;5. &amp;apos;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;As shown below.&lt;br /&gt;&lt;br /&gt; &lt;br /&gt;    strRemarks = Textbox.Replace("&amp;", "&amp;amp;")&lt;br /&gt;    strRemarks = strRemarks.Replace("&lt;", "&amp;lt;")&lt;br /&gt;    strRemarks = strRemarks.Replace("&gt;", "&amp;gt;")&lt;br /&gt;    strRemarks = strRemarks.Replace("""", "&amp;quot;")&lt;br /&gt;    strRemarks = strRemarks.Replace("'""'", "&amp;quot;")&lt;br /&gt;    strRemarks = strRemarks.Replace("'", "&amp;apos;")&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-2939478254361929892?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/2939478254361929892/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=2939478254361929892' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/2939478254361929892'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/2939478254361929892'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2009/02/exec-spxmlpreparedocument.html' title='EXEC SP_XML_PREPAREDOCUMENT'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-7164859331771730488</id><published>2009-01-12T23:07:00.001-08:00</published><updated>2009-01-12T23:10:05.559-08:00</updated><title type='text'>My Learnings...</title><content type='html'>The deadlines must not be streched.&lt;br /&gt;&lt;br /&gt;UNIT TESTING IS VERY IMPORTANT..&lt;br /&gt;&lt;br /&gt;When some resource tells, i've completed the module, they must show unit testing as well as functional...&lt;br /&gt;&lt;br /&gt;Provide complete information for the resources. Regarding their logic..&lt;br /&gt;&lt;br /&gt;Make Sure they are not hard coding any things in the Application..&lt;br /&gt;&lt;br /&gt;Before starting coding, do a brain storm session and ensure what reusable code and design can be help us out...&lt;br /&gt;&lt;br /&gt;DATE FORMATS ARE Always a headache.&lt;br /&gt;&lt;br /&gt;Use Convert.Datetime instead of Date.parse...&lt;br /&gt;&lt;br /&gt;ASP TEXTBOXES made as Readonly fields wont return any value to the server, So use always HTML input boxes for readonly (Calendar)&lt;br /&gt;&lt;br /&gt;Ensure that WBS is updated if necessary before start of coding.&lt;br /&gt;&lt;br /&gt;ALWAYS HAVE A PROPER TIME ESTIMATE..&lt;br /&gt;&lt;br /&gt;FROM THE NEXT PROJECT, JUST RECORD THE TIME REQUIRED TO COMPLETE A USP/ FORM OR WHATEVER, SO THAT WE CAN USE THAT INFORMATION FOR FURTHER TIME ESTIMTATION.&lt;br /&gt;&lt;br /&gt;ASK FOR THE TEAM'S LEAVE PLAN...&lt;br /&gt;&lt;br /&gt;ALWAYS BE PREPARED FOR ANY KINDA RISKS..&lt;br /&gt;&lt;br /&gt;production issues.. needs to be addresses...&lt;br /&gt;&lt;br /&gt;first ensure the design is proper in the stage of designing only.. Once done, we must not tinker with it always...&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;---------------------------------------------&lt;br /&gt;My Observations and learning’s while working on MER&lt;br /&gt;&lt;br /&gt;Requirement Gathering&lt;br /&gt;&lt;br /&gt;I. Don’t Assume Any thing, get information properly&lt;br /&gt;&lt;br /&gt;II. If we are gathering requirements for a particular page, then make sure all fields are covered, don’t miss even a single field.&lt;br /&gt;&lt;br /&gt;III. MOMz are a must. Also specify as much details as possible in the documents so that in future it wont affect the functionality&lt;br /&gt;&lt;br /&gt;IV. In SDD, Database level details must be specified very clearly.&lt;br /&gt;&lt;br /&gt;V. If there are some conditional constraints that are very decisive, then it must be clearly specified.&lt;br /&gt;&lt;br /&gt;VI. If there is any interaction with a third party system or a different system, then make sure, an exactly similar environment is available at the development end. Or else, while integrating both, problems are meant to rise and time also won’t be on our side.&lt;br /&gt;&lt;br /&gt;VII. Once the SRS and SDD are done, just go through the same and do as it says. Don’t assume or remember things and do. SRS / SDD must be the source for coding. Just Open it and type the code.&lt;br /&gt;&lt;br /&gt;VIII. It’s a very bad practice to start development without the SRS and SDD being signed off or else except more headaches in the later phases of the project where in the user may demand for requirements which you have not even heard of.&lt;br /&gt;&lt;br /&gt;IX. If something can be done technically in more than one way, Keep all the options in front of them and let them come back with the option feasible for them.&lt;br /&gt;&lt;br /&gt;a. For Example, Consider Client Side Validations, This can be done in the following ways&lt;br /&gt;&lt;br /&gt;i. Javascript (Which we follow religiously)&lt;br /&gt;ii. VB Script&lt;br /&gt;iii. Field Validators.&lt;br /&gt;&lt;br /&gt;So, instead of suffering last minute changes, we can avoid this at the requirement gathering stage itself.&lt;br /&gt;&lt;br /&gt;Database Design &lt;br /&gt;&lt;br /&gt;I. Do not have unnecessary table and Stored Procedures, which will just confuse us needlessly.&lt;br /&gt;&lt;br /&gt;II. Make sure for a particular field A, the data type and the size is correctly defined.&lt;br /&gt;&lt;br /&gt;III. Follow one Case, Either all BIG CAPS or all small caps. NeVeR  BOTH&lt;br /&gt;&lt;br /&gt;a. The above statement refers to the naming conventions of tables / views / stored procedures as well as Script statements&lt;br /&gt;&lt;br /&gt;IV. If there is interaction with another database, just make sure views are created to access the same instead of directly querying onto it.&lt;br /&gt;&lt;br /&gt;V. Creating VIEWS is very much important and it will reduce a lot of statement in the Where clause.&lt;br /&gt;&lt;br /&gt;VI. If we are inserting / updating to more than one table in a Stored Procedure, Sql Transaction statements are a MUST.&lt;br /&gt;&lt;br /&gt;VII. Also, most importantly try to follow the EXACT Coding Standards specified in the SDD.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Coding&lt;br /&gt;&lt;br /&gt;I. Also, most importantly try to follow the EXACT Coding Standards specified in the SDD.&lt;br /&gt;&lt;br /&gt;II. If there is some functionality which is common across the entire layer / Application, then use a common class file; write that piece of code here.&lt;br /&gt;&lt;br /&gt;a. If there are changes, then it can be easily dealt with.&lt;br /&gt;&lt;br /&gt;b. For example, if there is an ACTIVITYLOG functionality to be implemented, then &lt;br /&gt;&lt;br /&gt;III. Add one line of comment for every method and if there is some complex code written, a comment is always necessary there. All comments must be short and live up to the complexity of the code.&lt;br /&gt;&lt;br /&gt;IV. Make sure the pages cannot be directly accessed. Use Session Variables to ensure Direct Access to the application will not happen.&lt;br /&gt;&lt;br /&gt;V. All datasets / Sessions or other disposable resources must be disposed where ever applicable.&lt;br /&gt;&lt;br /&gt;VI. Try to user Data Reader where ever applicable, since the performance of the application will take a huge hike.&lt;br /&gt;&lt;br /&gt;Testing&lt;br /&gt;&lt;br /&gt;I. Try to see the application as a USER instead of a developer. There can be a chance wherein we can think of some changes that can help the user, do his work more effectively&lt;br /&gt;&lt;br /&gt;II. Give the code to someone very new to the application and so &lt;br /&gt;&lt;br /&gt;Implementation&lt;br /&gt;&lt;br /&gt;VII. G&lt;br /&gt;&lt;br /&gt;UAT&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;I. G&lt;br /&gt;&lt;br /&gt;II. Give more importance to Design as well, CSS and alignment details.&lt;br /&gt;&lt;br /&gt;III. Try &lt;br /&gt;&lt;br /&gt;IV. &lt;br /&gt;&lt;br /&gt;---------------------------------------------&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-7164859331771730488?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/7164859331771730488/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=7164859331771730488' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/7164859331771730488'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/7164859331771730488'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2009/01/my-learnings.html' title='My Learnings...'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-6337999829422352163</id><published>2009-01-10T01:38:00.000-08:00</published><updated>2009-01-10T01:44:52.699-08:00</updated><title type='text'></title><content type='html'>Been busy these days working with hectic Schedules.&lt;br /&gt;Been discovering many new ways and enjoying working with Sql Server.&lt;br /&gt;Creating Complex Stored Procedures and making Fun of&lt;br /&gt;&lt;br /&gt;Here is , which i created recently.&lt;br /&gt;Dynamically Create Columns and Rows from Two independent tables.&lt;br /&gt;This was for one fin Report and i spent 3 hrs for this.&lt;br /&gt;&lt;br /&gt;Try if you can digest it or else Move On...&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;-------------------------------------------&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;CREATE PROCEDURE USP_AUTO_MONTHLY_CONSOLIDATED_REPORT@PRODUCT_TYPE INT,@DATE_FROM DATETIME,@DATE_TO DATETIMEAS&lt;br /&gt;/*DECLARE @PRODUCT_TYPE INTSET @PRODUCT_TYPE = 141DECLARE @DATE_FROM DATETIMEDECLARE @DATE_TO DATETIMESET @DATE_FROM = '1/01/2008'SET @DATE_TO = '1/07/2009'*/&lt;br /&gt;BEGIN&lt;br /&gt; SET NOCOUNT ON&lt;br /&gt; DECLARE @TMP_DATE_FROM DATETIME DECLARE @MONTHNAME NVARCHAR(20) DECLARE @MONTHNO INT DECLARE @YEARNO INT&lt;br /&gt; SET @TMP_DATE_FROM = @DATE_FROM&lt;br /&gt; CREATE TABLE #TEMP_MONTH_YEAR_DETAILS (  MONTH_NAME NVARCHAR(20),  MONTH_NO INT,  YEAR_NO INT )&lt;br /&gt; WHILE @TMP_DATE_FROM &lt;= @DATE_TO BEGIN  SELECT @MONTHNAME =  CASE MONTH(@TMP_DATE_FROM)   WHEN 1 THEN 'January (' + CAST(YEAR(@TMP_DATE_FROM) AS NVARCHAR) + ')'   WHEN 2 THEN 'February ('  + CAST(YEAR(@TMP_DATE_FROM) AS NVARCHAR) + ')'   WHEN 3 THEN 'March ('  +  CAST(YEAR(@TMP_DATE_FROM) AS NVARCHAR) + ')'   WHEN 4 THEN 'April ('  +  CAST(YEAR(@TMP_DATE_FROM) AS NVARCHAR) + ')'   WHEN 5 THEN 'May ('  +  CAST(YEAR(@TMP_DATE_FROM) AS NVARCHAR) + ')'   WHEN 6 THEN 'June ('  +  CAST(YEAR(@TMP_DATE_FROM) AS NVARCHAR) + ')'   WHEN 7 THEN 'July ('  +  CAST(YEAR(@TMP_DATE_FROM) AS NVARCHAR) + ')'   WHEN 8 THEN 'August ('  +  CAST(YEAR(@TMP_DATE_FROM) AS NVARCHAR) + ')'   WHEN 9 THEN 'September ('  +  CAST(YEAR(@TMP_DATE_FROM) AS NVARCHAR) + ')'   WHEN 10 THEN 'October ('  +  CAST(YEAR(@TMP_DATE_FROM) AS NVARCHAR) + ')'   WHEN 11 THEN 'November ('  +  CAST(YEAR(@TMP_DATE_FROM) AS NVARCHAR) + ')'   WHEN 12 THEN 'December ('  +  CAST(YEAR(@TMP_DATE_FROM) AS NVARCHAR) + ')'  END&lt;br /&gt;  --SELECT @MONTHNAME  SET @MONTHNO =  MONTH(@TMP_DATE_FROM)  SET @YEARNO =  YEAR(@TMP_DATE_FROM)&lt;br /&gt;  IF NOT EXISTS (  SELECT MONTH_NO FROM #TEMP_MONTH_YEAR_DETAILS     WHERE      MONTH_NO = @MONTHNO      AND YEAR_NO = @YEARNO    )   INSERT INTO #TEMP_MONTH_YEAR_DETAILS   (MONTH_NAME , MONTH_NO ,  YEAR_NO)   VALUES   (@MONTHNAME,@MONTHNO,@YEARNO)&lt;br /&gt;  SET @TMP_DATE_FROM = DATEADD(MM,1,@TMP_DATE_FROM) END&lt;br /&gt;--SELECT * FROM #TEMP_MONTH_YEAR_DETAILS&lt;br /&gt;IF @PRODUCT_TYPE &lt;&gt; -1BEGIN&lt;br /&gt; SELECT O.MONTH_NAME,  ISNULL(A.TOTAL_INFLOW_COUNT,0) TOTAL_INFLOW_COUNT,  ISNULL(B.DECLINED,0) DECLINED_COUNT,  ISNULL(C.REJECTED,0) REJECTED_COUNT,  ISNULL(D.APPROVED,0) APPROVED_COUNT FROM (  SELECT * FROM #TEMP_MONTH_YEAR_DETAILS ) O  LEFT OUTER JOIN  (   SELECT    COUNT(MONTH(CREATED_ON)) TOTAL_INFLOW_COUNT,    MONTH(CREATED_ON) CREATED_MONTH,    YEAR(CREATED_ON) CREATED_YEAR   FROM    AT_AUTO_CE   WHERE    AT_AUTO_CE.FK_PRODUCT_TYPE = @PRODUCT_TYPE    AND AT_AUTO_CE.CREATED_ON BETWEEN @DATE_FROM AND @DATE_TO   GROUP BY MONTH(CREATED_ON),YEAR(CREATED_ON)    ) A  ON O.MONTH_NO = A.CREATED_MONTH  AND O.YEAR_NO = A.CREATED_YEAR  LEFT OUTER JOIN  (   SELECT    COUNT(MONTH(CREATED_ON)) DECLINED,    MONTH(CREATED_ON) CREATED_MONTH,    YEAR(CREATED_ON) CREATED_YEAR   FROM    AT_AUTO_CE   WHERE    FK_STATUS = 33    AND AT_AUTO_CE.CREATED_ON BETWEEN @DATE_FROM AND @DATE_TO    AND AT_AUTO_CE.FK_PRODUCT_TYPE = @PRODUCT_TYPE   GROUP BY MONTH(CREATED_ON),YEAR(CREATED_ON)    ) B    ON O.MONTH_NO = B.CREATED_MONTH  AND O.YEAR_NO = B.CREATED_YEAR  LEFT OUTER JOIN    (   SELECT    COUNT(MONTH(CREATED_ON)) REJECTED,    MONTH(CREATED_ON) CREATED_MONTH,    YEAR(CREATED_ON) CREATED_YEAR   FROM    AT_AUTO_CE   WHERE    FK_STATUS = 32    AND AT_AUTO_CE.FK_PRODUCT_TYPE = @PRODUCT_TYPE    AND AT_AUTO_CE.CREATED_ON BETWEEN @DATE_FROM AND @DATE_TO   GROUP BY MONTH(CREATED_ON),YEAR(CREATED_ON)    ) C&lt;br /&gt;  ON O.MONTH_NO = C.CREATED_MONTH  AND O.YEAR_NO = C.CREATED_YEAR  LEFT OUTER JOIN  (   SELECT    COUNT(MONTH(CREATED_ON)) APPROVED,    MONTH(CREATED_ON) CREATED_MONTH,    YEAR(CREATED_ON) CREATED_YEAR   FROM    AT_AUTO_CE   WHERE    FK_STATUS = 31    AND AT_AUTO_CE.FK_PRODUCT_TYPE = @PRODUCT_TYPE    AND AT_AUTO_CE.CREATED_ON BETWEEN @DATE_FROM AND @DATE_TO   GROUP BY MONTH(CREATED_ON),YEAR(CREATED_ON)  ) D  ON O.MONTH_NO = D.CREATED_MONTH  AND O.YEAR_NO = D.CREATED_YEAR&lt;br /&gt;ENDELSEBEGIN-- SELECT  O.MONTH_NAME,  ISNULL(A.TOTAL_INFLOW_COUNT,0) TOTAL_INFLOW_COUNT,  ISNULL(B.DECLINED,0) DECLINED_COUNT,  ISNULL(C.REJECTED,0) REJECTED_COUNT,  ISNULL(D.APPROVED,0) APPROVED_COUNT FROM (  SELECT * FROM #TEMP_MONTH_YEAR_DETAILS ) O  LEFT OUTER JOIN  (   SELECT    COUNT(MONTH(CREATED_ON)) TOTAL_INFLOW_COUNT,    MONTH(CREATED_ON) CREATED_MONTH,    YEAR(CREATED_ON) CREATED_YEAR   FROM    AT_AUTO_CE   WHERE    AT_AUTO_CE.CREATED_ON BETWEEN @DATE_FROM AND @DATE_TO   GROUP BY MONTH(CREATED_ON),YEAR(CREATED_ON)    ) A  ON O.MONTH_NO = A.CREATED_MONTH  AND O.YEAR_NO = A.CREATED_YEAR  LEFT OUTER JOIN  (   SELECT    COUNT(MONTH(CREATED_ON)) DECLINED,    MONTH(CREATED_ON) CREATED_MONTH,    YEAR(CREATED_ON) CREATED_YEAR   FROM    AT_AUTO_CE   WHERE    FK_STATUS = 33    AND AT_AUTO_CE.CREATED_ON BETWEEN @DATE_FROM AND @DATE_TO   GROUP BY MONTH(CREATED_ON),YEAR(CREATED_ON)    ) B    ON O.MONTH_NO = B.CREATED_MONTH  AND O.YEAR_NO = B.CREATED_YEAR  LEFT OUTER JOIN    (   SELECT    COUNT(MONTH(CREATED_ON)) REJECTED,    MONTH(CREATED_ON) CREATED_MONTH,    YEAR(CREATED_ON) CREATED_YEAR   FROM    AT_AUTO_CE   WHERE    FK_STATUS = 32    AND AT_AUTO_CE.CREATED_ON BETWEEN @DATE_FROM AND @DATE_TO   GROUP BY MONTH(CREATED_ON),YEAR(CREATED_ON)    ) C&lt;br /&gt;  ON O.MONTH_NO = C.CREATED_MONTH  AND O.YEAR_NO = C.CREATED_YEAR  LEFT OUTER JOIN  (   SELECT    COUNT(MONTH(CREATED_ON)) APPROVED,    MONTH(CREATED_ON) CREATED_MONTH,    YEAR(CREATED_ON) CREATED_YEAR   FROM    AT_AUTO_CE   WHERE    FK_STATUS = 31    AND AT_AUTO_CE.CREATED_ON BETWEEN @DATE_FROM AND @DATE_TO   GROUP BY MONTH(CREATED_ON),YEAR(CREATED_ON)  ) D  ON O.MONTH_NO = D.CREATED_MONTH  AND O.YEAR_NO = D.CREATED_YEAR--END DROP TABLE #TEMP_MONTH_YEAR_DETAILSEND&lt;br /&gt;GOSET QUOTED_IDENTIFIER OFF GOSET ANSI_NULLS ON GO&lt;br /&gt;SET QUOTED_IDENTIFIER ON GOSET ANSI_NULLS ON GO&lt;br /&gt;/**************************************************************************  SP&lt;br /&gt;************************************************************************/&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;CREATE  PROCEDURE USP_PRODUCTWISE_DEVIATION_REASON_REPORT@DATE_FROM DATETIME,@DATE_TO DATETIMEASBEGIN /*DECLARE @DATE_FROM DATETIME DECLARE @DATE_TO DATETIME --- ONLY FOR TESTING PURPOSE. SET @DATE_FROM = '1/1/1900' SET @DATE_TO = '1/1/2100'*/&lt;br /&gt; DECLARE @TEMP_SQL NVARCHAR(4000) -- THIS WILL HAVE A SQL SCRIPT FOR CREATING A NEW TABLE "TEMP_OUTPUT" DECLARE @TEMP_DATATYPE NVARCHAR(100) -- A SQL SCRIPT WHICH SPECIFIES DATATYPE OF THE COLUMNS IN "TEMP_OUTPUT" DECLARE @TEMP_PROD_TYPES NVARCHAR(100) -- THIS WILL STORE PRODCUTNAME WHICH WILL BE THE COLUMNS OF THE "TEMP_OUTPUT"&lt;br /&gt; DECLARE @TEMP_FINAL_SQL NVARCHAR(4000) -- THIS WILL HAVE A SQL SCRIPT TO UPDATE "TEMP_OUTPUT" WITH COUNTS. DECLARE @TEMP_SQL_COLUMN_NAME_QUERY NVARCHAR(4000) -- THIS WILL HAVE A SQL SCRIPT TO IDENTIFY WHICH COLUMN NEEDS TO BE UPDATED IN "TEMP_OUTPUT" DECLARE @TEMP_SQL_UPDATE_QUERY NVARCHAR(4000) -- THIS WILL HAVE A DEFAULT UPDATE SCRIPT DECLARE @TEMP_SQL_UPDATE_WHERE_QUERY NVARCHAR(4000)  -- THIS WILL HAVE A DEFAULT UPDATE SCRIPT WHERE CLAUSE&lt;br /&gt; DECLARE @TEMP_PROD NUMERIC(13,0)  -- THIS WILL STORE THE PRODUCTS DECLARE @TEMP_PROD_TWO NVARCHAR(1000)  -- THIS WILL ALSO STORE THE PRODUCTS, BUT AS A NVARCHAR DECLARE @TEMP_PROD_DESC NVARCHAR(1000)  -- THIS WILL STORE THE PRODUCT DESCRIPTION, SOMETHING LIKE PRODNAME_PRODID DECLARE @TEMP_DEVIATION_ID NUMERIC(13,0) -- THIS WILL STORE THE DEVIATION ID DECLARE @TEMP_DEVIATION_REASON NVARCHAR(100) -- THIS WILL STORE THE DEVIATION REASON DECLARE @PROD_COUNT_VALUE INT   -- THIS WILL STORE THE REQUIRED COUNTS OF EACH PRODUCT FOR EACH DEVIATION&lt;br /&gt; -- --BELOW THREE DECLARED VARIABLE, ARE USED TO GET THE UPDATE COLUMN. DECLARE @TARGET_COL NVARCHAR(100) DECLARE @UPDATE_COL NVARCHAR(100) DECLARE @TEMP_COL_OUTPUT NVARCHAR(100) --&lt;br /&gt; --BASIC TABLE CREATION QUERY SET @TEMP_SQL = ' CREATE TABLE TEMP_OUTPUT ([DEVIATION_REASON_SG_KEY] [numeric](13, 0) NOT NULL , DEVIATION_REASON NVARCHAR(200) ' SET @TEMP_DATATYPE = ' NVARCHAR(300) NULL ' --&lt;br /&gt; --BASIC TABLE UPDATE QUERY  SET @UPDATE_COL = &lt;a href="mailto:N"&gt;N'@TARGET_COL&lt;/a&gt; varchar(5000) OUTPUT'  SET @TEMP_SQL_UPDATE_QUERY = 'UPDATE TEMP_OUTPUT SET ' -- COLUMN NAME = VALUE  SET @TEMP_SQL_UPDATE_WHERE_QUERY = ' WHERE DEVIATION_REASON_SG_KEY =' --&lt;br /&gt; -- BEGIN "TEMP_OUTPUT" TABLE CREATION&lt;br /&gt; DECLARE CUR_FETCH_PROD_NAMES CURSOR  FOR&lt;br /&gt; SELECT TYPE_DESCRIPTION + '_'+  CAST(TYPE_CODE AS NVARCHAR) FROM AT_TYPE WHERE TYPE_FOR = 'Product Type' AND TYPE = 2 ORDER BY  TYPE_DESCRIPTION + '_'+  CAST(TYPE_CODE AS NVARCHAR)  DESC   OPEN  CUR_FETCH_PROD_NAMES&lt;br /&gt;  FETCH NEXT FROM CUR_FETCH_PROD_NAMES  INTO @TEMP_PROD_TYPES&lt;br /&gt;   WHILE @@FETCH_STATUS = 0   BEGIN    --SELECT @TEMP_PROD_TYPES    SET @TEMP_SQL = @TEMP_SQL + ', [' &lt;a href="mailto:+@TEMP_PROD_TYPES"&gt;+@TEMP_PROD_TYPES&lt;/a&gt; + ']'+ @TEMP_DATATYPE&lt;br /&gt;    FETCH NEXT FROM CUR_FETCH_PROD_NAMES    INTO @TEMP_PROD_TYPES   END&lt;br /&gt;   SET @TEMP_SQL = @TEMP_SQL + ' ) '     EXEC (@TEMP_SQL)   -- THE TABLE "TEMP_OUTPUT" IS CREATED, NOW ITS TIME TO DUMP IN RECORDS.&lt;br /&gt;   CLOSE CUR_FETCH_PROD_NAMES DEALLOCATE CUR_FETCH_PROD_NAMES -- CLEAR THE CURSOR CUR_FETCH_PROD_NAMES&lt;br /&gt;---------------------------------------------------------------------------------------------------------&lt;br /&gt; -- START TO INPUT DATA TO THE NEWLY CREATED "TEMP_OUTPUT" TABLE.&lt;br /&gt; DECLARE CUR_LOOP_PROD_NAMES CURSOR  FOR&lt;br /&gt; SELECT TYPE_DESCRIPTION + '_'+  CAST(TYPE_CODE AS NVARCHAR) , TYPE_CODE FROM AT_TYPE WHERE TYPE_FOR = 'Product Type' AND TYPE = 2 ORDER BY  TYPE_DESCRIPTION + '_'+  CAST(TYPE_CODE AS NVARCHAR)  DESC&lt;br /&gt;  OPEN  CUR_LOOP_PROD_NAMES&lt;br /&gt;  FETCH NEXT FROM CUR_LOOP_PROD_NAMES  INTO @TEMP_PROD_DESC, @TEMP_PROD  -- FETCH PROD DESCRIPTION AND PRODUCT ID&lt;br /&gt;   WHILE @@FETCH_STATUS = 0   BEGIN    SET @TEMP_PROD_TWO = ''    SET @TEMP_PROD_TWO = @TEMP_PROD    -- @TEMP_PROD_TWO WILL BE USED FOR THE DYNAMIC QUERY.    --PRINT @TEMP_PROD_TWO&lt;br /&gt;    DECLARE CUR_LOOP_DEVIATION_REASON CURSOR  FOR    SELECT DESCRIPTION,SG_KEY FROM AT_DEVIATION_MASTER&lt;br /&gt;     OPEN  CUR_LOOP_DEVIATION_REASON&lt;br /&gt;      FETCH NEXT FROM CUR_LOOP_DEVIATION_REASON      INTO @TEMP_DEVIATION_REASON,@TEMP_DEVIATION_ID      -- FETCH DEVIATION REASON AND DEVIATION ID&lt;br /&gt;       WHILE @@FETCH_STATUS = 0       BEGIN       --- CHECK IF DEVIATION SG_KEY IS PRESENT IN "TEMP_OUTPUT" TABLE.&lt;br /&gt;        IF NOT EXISTS(SELECT DEVIATION_REASON_SG_KEY FROM TEMP_OUTPUT          WHERE DEVIATION_REASON_SG_KEY = @TEMP_DEVIATION_ID)        BEGIN         -- DEVIATION_REASON_SG_KEY IS NOT PRESENT, SO INSERT.         INSERT INTO TEMP_OUTPUT(DEVIATION_REASON_SG_KEY,DEVIATION_REASON)         VALUES(@TEMP_DEVIATION_ID,@TEMP_DEVIATION_REASON)        END        ELSE        BEGIN         -- DEVIATION_REASON_SG_KEY IS PRESENT         --UPDATE "TEMP_OUTPUT" TABLE.&lt;br /&gt;         -- FETCH CORRESPONDING COUNT VALUES.         SET @PROD_COUNT_VALUE =             (            SELECT            ISNULL(COUNT(FK_PRODUCT_TYPE),0)            FROM             AT_AUTO_CE            WHERE             AT_AUTO_CE.CE_DEVTN = 1             AND AT_AUTO_CE.CE_DEVTN_REASON = @TEMP_DEVIATION_ID --AT_DEVIATION_MASTER.SG_KEY             AND AT_AUTO_CE.FK_PRODUCT_TYPE = @TEMP_PROD-- FK_PRODUCT_TYPE             AND AT_AUTO_CE.CREATED_ON BETWEEN @DATE_FROM AND @DATE_TO            GROUP BY             FK_PRODUCT_TYPE            )         -- ONLY UPDATE THE TABLE IF @PROD_COUNT_VALUE &lt;&gt; 0         -- OR ELSE THE VALUE WILL BE NULL, BT DEFAULT.         IF  @PROD_COUNT_VALUE &lt;&gt; 0         BEGIN          --SELECT  @PROD_COUNT_VALUE          --IDENTIFY THE COLUMN TO UPDATE THE VALUE         --          SET @TEMP_SQL_COLUMN_NAME_QUERY = 'SELECT @TARGET_COL =  column_name FROM INFORMATION_SCHEMA.COLUMNS WHERE table_name= ''TEMP_OUTPUT'' AND column_name LIKE''%'          SET @TEMP_SQL_COLUMN_NAME_QUERY = @TEMP_SQL_COLUMN_NAME_QUERY + @TEMP_PROD_TWO + ''''          --PRINT @TEMP_SQL_COLUMN_NAME_QUERY           EXECUTE sp_executesql           @TEMP_SQL_COLUMN_NAME_QUERY,           @UPDATE_COL,           @TARGET_COL = @TEMP_COL_OUTPUT OUTPUT          --SELECT @TEMP_COL_OUTPUT AS OUTT          -- NOW THE REQ COLUMN NAME WILL BE STORED IN @TEMP_COL_OUTPUT VARIABLE          SET @TEMP_FINAL_SQL = @TEMP_SQL_UPDATE_QUERY + '['+ @TEMP_COL_OUTPUT + '] =' + CAST(@PROD_COUNT_VALUE AS NVARCHAR) + @TEMP_SQL_UPDATE_WHERE_QUERY  + CAST(@TEMP_DEVIATION_ID AS NVARCHAR)          --PRINT @TEMP_FINAL_SQL          -- @TEMP_FINAL_SQL WILL HOLD THE FINAL UPDATE QUERY.          EXEC(@TEMP_FINAL_SQL) -- UPDATED THE "TEMP_OUTPUT" TABLE.         END--        END      FETCH NEXT FROM CUR_LOOP_DEVIATION_REASON      INTO @TEMP_DEVIATION_REASON,@TEMP_DEVIATION_ID     END&lt;br /&gt;      CLOSE CUR_LOOP_DEVIATION_REASON    DEALLOCATE CUR_LOOP_DEVIATION_REASON&lt;br /&gt;   FETCH NEXT FROM CUR_LOOP_PROD_NAMES   INTO @TEMP_PROD_DESC, @TEMP_PROD  END&lt;br /&gt;   CLOSE CUR_LOOP_PROD_NAMES DEALLOCATE CUR_LOOP_PROD_NAMES&lt;br /&gt;--------------------------------------------------------------------------------------------------------&lt;br /&gt;  SELECT * FROM TEMP_OUTPUT   DROP TABLE TEMP_OUTPUTEND&lt;br /&gt;GOSET QUOTED_IDENTIFIER OFF GOSET ANSI_NULLS ON GO&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-6337999829422352163?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/6337999829422352163/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=6337999829422352163' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/6337999829422352163'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/6337999829422352163'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2009/01/been-busy-these-days-working-with.html' title=''/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-3509595226852946297</id><published>2008-05-14T03:37:00.000-07:00</published><updated>2008-05-14T03:37:55.060-07:00</updated><title type='text'>Molloys r us : Set page title dynamically in asp.net</title><content type='html'>&lt;a href="http://blogs.vertigosoftware.com/liam/archive/2005/05/20/927.aspx"&gt;Molloys r us : Set page title dynamically in asp.net&lt;/a&gt;: "Set page title dynamically in asp.net&lt;br /&gt;&lt;br /&gt;There is no page title web control within asp.net so how would you set a page title Programmatically?&lt;br /&gt;&lt;br /&gt;You can add an ID and Runat attribute to the existing title tag:&lt;br /&gt;&lt;br /&gt;Within your code behind file add a html generic control with the other control declarations:&lt;br /&gt;&lt;br /&gt;protected System.Web.UI.HtmlControls.HtmlGenericControl pageTitle;&lt;br /&gt;&lt;br /&gt;The title can now be accessed programmatically just like any other web control:"&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-3509595226852946297?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://blogs.vertigosoftware.com/liam/archive/2005/05/20/927.aspx' title='Molloys r us : Set page title dynamically in asp.net'/><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/3509595226852946297/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=3509595226852946297' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/3509595226852946297'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/3509595226852946297'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/05/molloys-r-us-set-page-title-dynamically.html' title='Molloys r us : Set page title dynamically in asp.net'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-5764962405744291741</id><published>2008-04-25T04:57:00.000-07:00</published><updated>2008-04-25T04:57:09.540-07:00</updated><title type='text'>"No Records Found" Message in Reporting Services - Brian Mains Blog</title><content type='html'>&lt;a href="http://dotnetslackers.com/community/blogs/bmains/archive/2007/07/02/_2200_No-Records-Found_2200_-Message-in-Reporting-Services.aspx"&gt;"No Records Found" Message in Reporting Services - Brian Mains Blog&lt;/a&gt;: "I was trying to display a message in my report, that when no records were found from the underlying query, a message would be displayed like 'no records found' or something like that.  I couldn't find the answer until I came across a forum post, and so I include it in case it helps someone else:   https://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1659610&amp;amp;SiteID=1"&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-5764962405744291741?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://dotnetslackers.com/community/blogs/bmains/archive/2007/07/02/_2200_No-Records-Found_2200_-Message-in-Reporting-Services.aspx' title='&quot;No Records Found&quot; Message in Reporting Services - Brian Mains Blog'/><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/5764962405744291741/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=5764962405744291741' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/5764962405744291741'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/5764962405744291741'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/04/no-records-found-message-in-reporting.html' title='&quot;No Records Found&quot; Message in Reporting Services - Brian Mains Blog'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-6110633709367054514</id><published>2008-03-20T10:17:00.000-07:00</published><updated>2008-03-20T10:19:19.080-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='Errors'/><title type='text'>Return False.. :)</title><content type='html'>I had  written a j.s for onclick event and even though i had clicked it.&lt;br /&gt;&lt;br /&gt;This was the code that i used to call the j.s&lt;br /&gt;&lt;br /&gt;            chk.Attributes.Add("onclick", "javascript:Temp('" &amp; CType(dgi.FindControl("ddMapToColumn"), DropDownList).ClientID &amp; "'); return false")&lt;br /&gt;&lt;br /&gt;But, to my surprise, even after checking the checkbox, the tick mark on the check box wasn't coming.&lt;br /&gt;&lt;br /&gt;The reason for which is the "return false;" statement.&lt;br /&gt;&lt;br /&gt;This was something that i learned after googling&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-6110633709367054514?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/6110633709367054514/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=6110633709367054514' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/6110633709367054514'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/6110633709367054514'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/03/return-false.html' title='Return False.. :)'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-6965025048796750147</id><published>2008-03-20T10:15:00.000-07:00</published><updated>2008-03-20T10:16:25.164-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='DataGrid'/><category scheme='http://www.blogger.com/atom/ns#' term='Check box'/><title type='text'>DataGrid + On Click of Check box, Enable or Disable a Drop Down</title><content type='html'>This is how it goes..&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Add Attributes to the checkbox in item data bound&lt;br /&gt;&lt;br /&gt;For Each dgi In dgCol.Items&lt;br /&gt;            Dim chk As CheckBox = CType(dgi.FindControl("chkSelect"), CheckBox)&lt;br /&gt;            chk.Attributes.Add("onclick", "javascript:Temp('" &amp; CType(dgi.FindControl("ddMapToColumn"), DropDownList).ClientID &amp; "');")&lt;br /&gt;Next&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;The Java script that does the Enabling / Disabling is as follows..&lt;br /&gt;&lt;br /&gt;function Temp(drpdown)&lt;br /&gt;    {&lt;br /&gt;        document.getElementById(drpdown).disabled = !document.getElementById(drpdown).disabled;&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt; &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Nothing much is required apart from this and the job is done !!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-6965025048796750147?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/6965025048796750147/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=6965025048796750147' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/6965025048796750147'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/6965025048796750147'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/03/datagrid-on-click-of-check-box-enable.html' title='DataGrid + On Click of Check box, Enable or Disable a Drop Down'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-4393686326094012430</id><published>2008-03-20T10:11:00.000-07:00</published><updated>2008-03-20T10:14:08.923-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='Query String'/><title type='text'>Retrieve Query String Parameters using Javascripts</title><content type='html'>Retrieve Query String Parameters using Javascripts&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Parameters are coming, but its giving an obj not found error, Need to Check that out&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;   "&lt;script language='JavaScript'&gt;&lt;br /&gt;        // get the current URL&lt;br /&gt;        var url = window.location.toString();&lt;br /&gt;        //get the parameters&lt;br /&gt;        url.match(/\?(.+)$/);&lt;br /&gt;        var params = RegExp.$1;&lt;br /&gt;        // split up the query string and store in an&lt;br /&gt;        // associative array&lt;br /&gt;        var params = params.split("&amp;");&lt;br /&gt;        var queryStringList = {};&lt;br /&gt;         &lt;br /&gt;        for(var i=0; "i&lt;params.length;i++)&lt;br /&gt;        {&lt;br /&gt;             var tmp = params[i].split("=");&lt;br /&gt;             queryStringList[tmp[0]] = unescape(tmp[1]);&lt;br /&gt;        }&lt;br /&gt;         &lt;br /&gt;        // print all querystring in key value pairs&lt;br /&gt;        for(var i in queryStringList) "&lt;br /&gt;             doc.write(i+" = "+queryStringList[i]+"&lt;br/&gt;");&lt;br /&gt;        "&lt;/script&gt;"&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-4393686326094012430?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/4393686326094012430/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=4393686326094012430' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/4393686326094012430'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/4393686326094012430'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/03/retrieve-query-string-parameters-using.html' title='Retrieve Query String Parameters using Javascripts'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-8197977803818131578</id><published>2008-03-20T10:08:00.001-07:00</published><updated>2008-03-20T10:11:28.345-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Javascript'/><category scheme='http://www.blogger.com/atom/ns#' term='DataGrid'/><category scheme='http://www.blogger.com/atom/ns#' term='Check box'/><title type='text'>Data Grid + Checkboxes...</title><content type='html'>This is Useful when you have a Grid and u need to use javascripts for Each element , in this ex its Check Box&lt;br /&gt;&lt;br /&gt;Here is the ASP code&lt;br /&gt;&lt;br /&gt;//&lt;br /&gt;// this html tag adds checkbox to header&lt;br /&gt;//&lt;br /&gt;&lt;asp:TemplateColumn&gt; &lt;br /&gt; &lt;HeaderTemplate&gt; &lt;br /&gt;  &lt;Input id="checkAll" type=checkbox &lt;br /&gt;    onclick="DGSelectOrUnselectAll('DataGrid1',this,'chkDel')" &gt; &lt;br /&gt; &lt;/HeaderTemplate&gt;&lt;br /&gt; //&lt;br /&gt; // this html tag adds checkbox to datagrid&lt;br /&gt; &lt;ItemTemplate&gt; &lt;br /&gt;  &lt;asp:CheckBox ID="chkDel" Runat="server"&gt;&lt;/asp:CheckBox&gt; &lt;br /&gt; &lt;/ItemTemplate&gt; &lt;br /&gt;&lt;/asp:TemplateColumn&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Below is the Java Script&lt;br /&gt;&lt;br /&gt;//-------------------------------------------------------&lt;br /&gt;//this is to select or unselect the datagrid check boxes &lt;br /&gt;&lt;br /&gt;function DGSelectOrUnselectAll(grdid,obj,objlist){ &lt;br /&gt;//this function decides whether to check or uncheck all&lt;br /&gt;    if(obj.checked) &lt;br /&gt;        DGSelectAll(grdid,objlist) &lt;br /&gt;    else &lt;br /&gt;        DGUnselectAll(grdid,objlist) &lt;br /&gt;} &lt;br /&gt;//---------- &lt;br /&gt; &lt;br /&gt;function DGSelectAll(grdid,objid){ &lt;br /&gt;//.this function is to check all the items&lt;br /&gt;    var chkbox; &lt;br /&gt;    var i=2; &lt;br /&gt;&lt;br /&gt;    chkbox=document.getElementById(grdid + &lt;br /&gt;               '__ctl' + i + '_' + objid); &lt;br /&gt;&lt;br /&gt;    while(chkbox!=null){ &lt;br /&gt;        chkbox.checked=true; &lt;br /&gt;        i=i+1; &lt;br /&gt;        chkbox=document.getElementById(grdid + &lt;br /&gt;                   '__ctl' + i + '_' + objid); &lt;br /&gt;    } &lt;br /&gt;&lt;br /&gt;}//-------------- &lt;br /&gt;&lt;br /&gt;function DGUnselectAll(grdid,objid){ &lt;br /&gt;//.this function is to uncheckcheck all the items&lt;br /&gt;    var chkbox; &lt;br /&gt;    var i=2; &lt;br /&gt;&lt;br /&gt;    chkbox=document.getElementById(grdid + &lt;br /&gt;               '__ctl' + i + '_' + objid); &lt;br /&gt;&lt;br /&gt;    while(chkbox!=null){ &lt;br /&gt;        chkbox.checked=false; &lt;br /&gt;        i=i+1; &lt;br /&gt;        chkbox=document.getElementById(grdid + &lt;br /&gt;                   '__ctl' + i + '_' + objid); &lt;br /&gt;    } &lt;br /&gt;}&lt;br /&gt;//-------------------------------------------------------&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;THIS IS USEFUL TO CHECK OR UNCHECK CHECKBOXES IN A GRID.&lt;br /&gt;&lt;br /&gt;PS: THIS ONLY AFFECTS THE CURRENT PAGE CONTENTS OF THE GRID.&lt;br /&gt;         IF YOU NEED THE SAME TO AFFECT ALL OTHER PAGES, THEN WE NEED TO CUSTOMISE THE ABOVE CODE&lt;br /&gt;         BY ADDING A HIDDEN VARIABLE AND SETTING IT TO SOME VALUE WHICH IF SET, THEN CHECKS ALL CHECK BOXES&lt;br /&gt;         WHEN WE LOAD THE PAGE.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-8197977803818131578?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/8197977803818131578/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=8197977803818131578' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/8197977803818131578'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/8197977803818131578'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/03/data-grid-checkboxes.html' title='Data Grid + Checkboxes...'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-8970389809761905670</id><published>2008-02-22T09:59:00.000-08:00</published><updated>2008-02-22T10:03:36.606-08:00</updated><title type='text'>Little Animation on the web page!</title><content type='html'>I was googling something and suddenly i found this particular technical web site.. &lt;a href="http://nishant.hopto.org/wordpress/"&gt;http://nishant.hopto.org/wordpress/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;There is nothing much in the site but i found this interting though !&lt;br /&gt;&lt;br /&gt;And found this Cool thing which we can add to a ASPX page, meta content part and check out the amazing way to ignore the postback.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Just paste the below TAG in your HTML, it will cause IE to use DirectX transformation to render your page. This gives a very cool and pleasing look.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;""&lt;"meta equiv="”Page-Exit”" content="”progid:DXImageTransform.Microsoft.Fade(duration=".5)”"&gt;""&lt;br /&gt;&lt;br /&gt;The way I understand this works is that IE sends a request for the new page but does not clear the page you have on your screen right now. When IE has the second page ready in the buffer, it just uses DirectX to transform the image of the previous page into the image of the new page.&lt;br /&gt;&lt;br /&gt;You can try these other effects too :&lt;br /&gt;&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.Wheel(duration=0.5,spokes=5)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.Barn(duration=0.5,orientation=horizontal)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.Blinds(duration=0.5,bands=5)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.CheckerBoard(duration=0.5)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.Fade(duration=0.5)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.GradientWipe(duration=0.5,wipeStyle=0)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.Iris(duration=0.5,irisStyle=STAR)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.Iris(duration=0.5,irisStyle=CIRCLE)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.Pixelate(duration=0.5,maxSquare=40)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.Wheel(duration=0.5,spokes=5)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.RandomDissolve(duration=0.5)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.Spiral(duration=0.5)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.Stretch(duration=0.5,stretchStyle=push)”&lt;br /&gt;content=”progid:DXImageTransform.Microsoft.Strips(duration=0.5,motion=rightdown)”&lt;br /&gt;&lt;br /&gt;Plus, you can apply these affects at various points in your site or web pages :&lt;br /&gt;&lt;br /&gt;meta http-equiv=”Page-Enter”&lt;br /&gt;meta http-equiv=”Page-Exit”&lt;br /&gt;meta http-equiv=”Site-Enter”&lt;br /&gt;meta http-equiv=”Site-Exit“&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-8970389809761905670?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/8970389809761905670/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=8970389809761905670' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/8970389809761905670'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/8970389809761905670'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/02/little-animation-on-web-page.html' title='Little Animation on the web page!'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-219127583601331582</id><published>2008-02-22T09:56:00.001-08:00</published><updated>2008-02-22T09:56:54.157-08:00</updated><title type='text'>Clearing Session Variables</title><content type='html'>Session.Abandon and Session.Clear() is the two methods that gave me a HUGE headache for the day.&lt;br /&gt;&lt;br /&gt;Logout isnt working as i wanted. Only after a postback, its clearing the controls.&lt;br /&gt;&lt;br /&gt;What to do, I Donno.. If i get the solution, ill try to add it here.&lt;br /&gt;&lt;br /&gt;This was the Code That i was using in the LOG OUT Page LOAD&lt;br /&gt;&lt;br /&gt;Session.Abandon()&lt;br /&gt;Response.Cache.SetCacheability(HttpCacheability.No Cache)&lt;br /&gt;Response.Cache.SetExpires(Now().AddSeconds(-1))&lt;br /&gt;Response.Cache.SetNoStore()&lt;br /&gt;Response.AddHeader("Pragma", "no-cache")&lt;br /&gt;&lt;br /&gt;This also didnt help much. Later i Added this particular line in all the ASPX pages.&lt;br /&gt;&lt;br /&gt;&lt;%@ OutputCache Location = "none" %&gt;&lt;br /&gt;&lt;br /&gt;FINALLY IT WORKED. NOW ITS FINE, BUT STILL UNSURE, WHY IT WAS NOT WORKING.&lt;br /&gt;&lt;br /&gt;THIS IS ONE OF THE SIMPLEST REASON, WHY WEB DEVELOPMENT IS "NOT SO EASY"&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-219127583601331582?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/219127583601331582/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=219127583601331582' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/219127583601331582'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/219127583601331582'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/02/clearing-session-variables.html' title='Clearing Session Variables'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-446065179529055493</id><published>2008-02-09T00:26:00.000-08:00</published><updated>2008-02-09T00:28:00.008-08:00</updated><title type='text'>Important Sql Server 2000 Queries !!</title><content type='html'>&lt;span style="font-family:Times New Roman;font-size:100%;"&gt;&lt;span style="font-size: 12pt;"&gt;I'll try to add some important Sql Server Queries in the below post.&lt;br /&gt;This will be handy for me some day.&lt;br /&gt;&lt;br /&gt;Q1 : To select Column Names from a table:&lt;br /&gt;&lt;br /&gt;    SELECT  column_name &lt;/span&gt;&lt;/span&gt; &lt;p&gt;&lt;span style="font-family:Times New Roman;font-size:100%;"&gt;&lt;span style="font-size: 12pt;"&gt;            FROM  INFORMATION_SCHEMA.COLUMNS &lt;/span&gt;&lt;/span&gt;&lt;/p&gt; &lt;p&gt;&lt;span style="font-family:Times New Roman;font-size:100%;"&gt;&lt;span style="font-size: 12pt;"&gt;                   WHERE  table_name= 'YOUR TABLE NAME'&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-446065179529055493?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/446065179529055493/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=446065179529055493' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/446065179529055493'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/446065179529055493'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/02/important-sql-server-2000-queries.html' title='Important Sql Server 2000 Queries !!'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-700391157402349972</id><published>2008-02-09T00:21:00.003-08:00</published><updated>2008-02-09T00:21:59.792-08:00</updated><title type='text'>Modified Date of a DB object - Sql Server 2000</title><content type='html'>Some days Back i had a particular requirement like.. i wanted to identify the modified datetime of a Database object in Sql Server 2000.&lt;br /&gt;&lt;br /&gt;We have the table called sysobjects in every database which is supposed to store all these information.&lt;br /&gt;&lt;br /&gt;There are two columns which is of interest for the above scenario&lt;br /&gt;&lt;br /&gt;1. crdate Created Date&lt;br /&gt;2. refdate - ( This also stored the Created Date only )&lt;br /&gt;&lt;br /&gt;After i saw refdate, i was really excited and thought that this was the column which stores the modified datetime of a Database object.&lt;br /&gt;But my excitement came down even more quickly as it also stored the date of Creation of the object.&lt;br /&gt;&lt;br /&gt;Thought Google Is God and started Googling.&lt;br /&gt;&lt;br /&gt;After googling for some time, Guess what i discoverd, There is no way u can get the Modified datetime of a Database object in Sql Server 2000.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;The day after, i was just googling around for the same.&lt;br /&gt;&lt;br /&gt;I knew all Changes to the database are recorded in the log files, So if i was able to read / Query the Sql Log files, i was able to meet my requirement.&lt;br /&gt;&lt;br /&gt;I tried to open the Sql Log in a notapad, after stopping the server, but there was nothing in a readable format.&lt;br /&gt;&lt;br /&gt;I Googled Again....... ;( "How to read Sql Log files"&lt;br /&gt;&lt;br /&gt;And i finally found some thing interesting, &lt;b&gt;&lt;i&gt;DBCC&lt;/i&gt;&lt;/b&gt;..&lt;br /&gt;&lt;p&gt;DBCC is an abbreviation for &lt;i&gt;Database Console Command&lt;/i&gt;. DBCC commands are generally used to check the physical and logical consistency of a database, although they are also used for a variety of miscellaneous tasks that can be done.&lt;/p&gt;These are not popular things which are known to everyone...&lt;br /&gt;&lt;br /&gt;There is a command called dbcc log&lt;br /&gt;&lt;br /&gt;                  whose signature looks like dbcc log(databasename/dbid, type)&lt;br /&gt;&lt;br /&gt;Ex : DBCC log(temp,3)&lt;br /&gt;&lt;br /&gt;I thought this will provide information which we cant digest...&lt;br /&gt;&lt;br /&gt;The quest for my requirement continues....&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;For the time being....&lt;br /&gt;Chao....&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Happy Coding&lt;br /&gt;&lt;br /&gt;----------------------------------------------------------------------------------------------------------------------------&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-700391157402349972?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/700391157402349972/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=700391157402349972' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/700391157402349972'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/700391157402349972'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/02/modified-date-of-db-object-sql-server.html' title='Modified Date of a DB object - Sql Server 2000'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-4769350918419510751</id><published>2008-02-09T00:20:00.000-08:00</published><updated>2008-02-09T00:21:03.810-08:00</updated><title type='text'>Sql Server 2000 - Providing Permissions</title><content type='html'>Providing Permissions for a New database Login User.&lt;br /&gt;&lt;br /&gt;Some days back, we had a new requirement, where in we need to create a separate database user to access the application.&lt;br /&gt;This user must not be the DB owner.&lt;br /&gt;&lt;br /&gt;So, we created the user in the Sql Server Enterprise Manager --&gt; Security --&gt; Logins --&gt; New Login.&lt;br /&gt;&lt;br /&gt;Now, we had provide the New Login name, and choose the type of authentication required for the user&lt;br /&gt;A. Windows Authentication&lt;br /&gt;B. Sql Server Authentication.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;As per our requirement, we choose B, and provided the credentials.&lt;br /&gt;&lt;br /&gt;The next step is to select the Database and the Language.&lt;br /&gt;&lt;br /&gt;Now, Goto Database Access Tab and we need to CHECK the databases that this new user need to access.&lt;br /&gt;&lt;br /&gt;After checking, we need to assign the roles for this user&lt;br /&gt;&lt;br /&gt;db_datareader and db_datawriter will ensure this user to select or Insert into tables / views.&lt;br /&gt;&lt;br /&gt;After this, we need to provide the execute permission for the Stored Procedures which need to done manually for each and every SP.&lt;br /&gt;&lt;br /&gt;This is a tiresome process if we've more SP.&lt;br /&gt;&lt;br /&gt;After Googling around, i found a script which will output a Script which if run, will provide the permissions for the user to execute SPs.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;This script really came Handy !!&lt;br /&gt;&lt;br /&gt;select 'Grant Execute on ' + name +  ' to ' + 'SQLServerUSERName'&lt;br /&gt;from sysobjects where xtype in ('P')&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Just Change "SQLServerUSERName" to the New DB Login Name and Magic... The output of this script gives u a set of select statements which u need to execute and Thatz it, The permissions are provided for the user.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Happy Coding&lt;br /&gt;&lt;br /&gt;----------------------------------------------------------------------------------------------------------------------------&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-4769350918419510751?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/4769350918419510751/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=4769350918419510751' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/4769350918419510751'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/4769350918419510751'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/02/sql-server-2000-providing-permissions.html' title='Sql Server 2000 - Providing Permissions'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-9056645830275082312</id><published>2008-02-09T00:18:00.000-08:00</published><updated>2008-02-09T00:20:10.753-08:00</updated><title type='text'>Windows Authentication</title><content type='html'>We are working on an Intranet Application which has Windows Authentication.&lt;br /&gt;&lt;br /&gt;Following piece of code, gets you the name of the user who has logged in.&lt;br /&gt;&lt;br /&gt;---&lt;br /&gt;&lt;p&gt;&lt;span style="font-family:Verdana;font-size:85%;color:black;"&gt;&lt;span style="font-size: 10pt; color: black; font-family: Verdana;"&gt;Imports  System.Globalization&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;        &lt;p&gt;&lt;span style="font-family:Verdana;font-size:85%;color:black;"&gt;&lt;span style="font-size: 10pt; color: black; font-family: Verdana;"&gt;&lt;br /&gt;Dim  GetUser As String&lt;br /&gt;Dim  strUID() As String&lt;br /&gt;Dim User  As System.Security.Principal.IPrincipal&lt;br /&gt;User =  System.Web.HttpContext.Current.User&lt;br /&gt;GetUser  = &lt;a href="http://user.identity.name/"&gt;User.Identity.Name&lt;/a&gt;&lt;br /&gt;strUID =  GetUser.Split("\")&lt;br /&gt;GetUser  = strUID(1)&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;---&lt;br /&gt;&lt;br /&gt;Once we put this code, we should get the logged in User's Name in the GetUser var.&lt;br /&gt;&lt;br /&gt;But, we are facing some problems in a few systems where this name is getting populated  incorrectly.&lt;br /&gt;&lt;br /&gt;Instead of the Logged in user's name,   we are getting the server's login name.&lt;br /&gt;&lt;br /&gt;Googling around to solve this problem, ,no luck yet.&lt;br /&gt;&lt;br /&gt;Once i solve this, ill put the solution here.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Happy Coding&lt;br /&gt;&lt;br /&gt;----------------------------------------------------------------------------------------------------------------------------&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-9056645830275082312?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/9056645830275082312/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=9056645830275082312' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/9056645830275082312'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/9056645830275082312'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/02/windows-authentication.html' title='Windows Authentication'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-8316423368642987244</id><published>2008-01-17T21:49:00.000-08:00</published><updated>2008-01-17T21:53:11.336-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='CSS'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><title type='text'></title><content type='html'>Long time posting on the Blogger&lt;br /&gt;&lt;br /&gt;Since yesterday i'm having problems with CSS.&lt;br /&gt;&lt;br /&gt;I've googled down the hidden treasures that protect the secret of a writing a Valid CSS.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Following links are handy&lt;br /&gt;&lt;br /&gt;&lt;dl&gt;&lt;dt&gt;W3C HTML Validator:  &lt;a href="http://validator.w3.org/"&gt;http://validator.w3.org/&lt;/a&gt;&lt;/dt&gt;&lt;dd&gt;&lt;br /&gt;&lt;/dd&gt;&lt;dt&gt;WDG HTML Validator:  &lt;a href="http://www.htmlhelp.org/tools/validator/"&gt;http://www.htmlhelp.org/tools/validator/&lt;/a&gt;&lt;/dt&gt;&lt;dd&gt;&lt;br /&gt;&lt;/dd&gt;&lt;dt&gt;CSS Validator:  &lt;a href="http://jigsaw.w3.org/css-validator/"&gt;http://jigsaw.w3.org/css-validator/&lt;/a&gt;&lt;/dt&gt;&lt;dd&gt;&lt;br /&gt;&lt;/dd&gt;&lt;dt&gt;WDG's CSScheck:  &lt;a href="http://www.htmlhelp.org/tools/csscheck/"&gt;http://www.htmlhelp.org/tools/csscheck/&lt;/a&gt;&lt;/dt&gt;&lt;/dl&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Got em from a web site&lt;br /&gt;http://meyerweb.com/&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-8316423368642987244?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/8316423368642987244/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=8316423368642987244' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/8316423368642987244'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/8316423368642987244'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2008/01/long-time-posting-on-blogger-since.html' title=''/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-947741711405330889</id><published>2007-07-03T00:00:00.000-07:00</published><updated>2007-07-03T00:22:59.682-07:00</updated><title type='text'>Connection String......</title><content type='html'>Did u ever had a tough time writing a connection string to a Database...&lt;br /&gt;&lt;br /&gt;Here is the easiest method of all...&lt;br /&gt;&lt;br /&gt;Its Soo simple and easy and u can just have ur Connection string just using only a notepad.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;All u gotta do is to Create a New Notepad Docuement and save it as FileName.UDL file&lt;br /&gt;&lt;br /&gt;Now double click on the same file and use the wizard to configure ur connection with the DataBase..&lt;br /&gt;&lt;br /&gt;Now once all the confoigurations are done, Close the file and reopen it using Note pad or any text editor...&lt;br /&gt;&lt;br /&gt;There u go, Ur Connection String is ready.&lt;br /&gt;&lt;br /&gt;Ur String may looks like this&lt;br /&gt;&lt;br /&gt;.&lt;br /&gt;.&lt;br /&gt;.&lt;br /&gt;[oledb]; Everything after this line is an OLE DB initstringProvider=SQLOLEDB.1;Persist Security Info=False;User ID=dbuser;Initial Catalog=INDUB;Data Source=NESSQLSRV&lt;br /&gt;.&lt;br /&gt;.&lt;br /&gt;.&lt;br /&gt;&lt;br /&gt;Now u knw how easy it is to write connection strings without a need to remember many things.....&lt;br /&gt;&lt;br /&gt;Happy Coding...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-947741711405330889?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/947741711405330889/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=947741711405330889' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/947741711405330889'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/947741711405330889'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2007/07/connection-string.html' title='Connection String......'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-4225025751055100342</id><published>2007-06-27T01:14:00.000-07:00</published><updated>2007-06-27T03:31:50.973-07:00</updated><title type='text'>Sql Server : Under the HOod</title><content type='html'>&lt;span style="font-family:georgia;"&gt;Just experimenting with a  few things in &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;sql&lt;/span&gt; Server 2000&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Rules&lt;br /&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;raiserror&lt;/span&gt;&lt;br /&gt;User Defined Data Types&lt;br /&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;SYSOBJECTS&lt;/span&gt;&lt;br /&gt;Check constraints&lt;br /&gt;&lt;br /&gt;A Couple of Stored Procedure&lt;br /&gt;               SP_&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;BINDRULE&lt;/span&gt;&lt;br /&gt;               SP_&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;UNBINDRULE&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Lets take up one by one...&lt;br /&gt;&lt;br /&gt;Rule : A constraint that can be applied to a particular column or User Defined Data Type (&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;UDT&lt;/span&gt;)&lt;br /&gt;&lt;br /&gt;Syntax : create rule &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_6"&gt;RuleName&lt;/span&gt;&lt;br /&gt;                 as&lt;br /&gt;                      Condition_Expression&lt;br /&gt;&lt;br /&gt;Example : Create Rule &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_7"&gt;RuleOne&lt;/span&gt;&lt;br /&gt;                   as&lt;br /&gt;                       @&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_8"&gt;EMPNO&lt;/span&gt; &lt;&gt; 5&lt;br /&gt;&lt;br /&gt;So now, to apply this newly created rule to a Table Column or &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_9"&gt;UDT&lt;/span&gt;, We use the Stored Procedure, SP_&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_10"&gt;BINDRULE&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Syntax&lt;br /&gt;                  SP_&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_11"&gt;BINDRULE&lt;/span&gt; [ @rulename = ] 'rule' ,&lt;br /&gt;                                               [ @objname = ] 'object_name'&lt;br /&gt;                                               [ , [ @futureonly = ] '&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_12"&gt;futureonly&lt;/span&gt;_flag' ]&lt;br /&gt;&lt;br /&gt;This Procedure takes 3 arguments&lt;br /&gt;&lt;br /&gt;1) &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_13"&gt;Rulename&lt;/span&gt; : The Name of the rule which we want to apply&lt;br /&gt;2) &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_14"&gt;ObjectName&lt;/span&gt; : Name of the Table Column  or &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_15"&gt;UDT&lt;/span&gt;.&lt;br /&gt;3) &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_16"&gt;Futureonly&lt;/span&gt; :  If this field is set, it means the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_17"&gt;contraints&lt;/span&gt; applies in future and not for  information already existing in the database.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Example1 : &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_18"&gt;sp&lt;/span&gt;_&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_19"&gt;bindrule&lt;/span&gt; &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_20"&gt;RuleOne&lt;/span&gt;, 'Sandy'&lt;br /&gt;&lt;br /&gt;Here, &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_21"&gt;RuleOne&lt;/span&gt; is the Name of the Rule and 'Sandy' is a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_22"&gt;UDT&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Example2 : &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_23"&gt;sp&lt;/span&gt;_&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_24"&gt;bindrule&lt;/span&gt; &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_25"&gt;RuleOne&lt;/span&gt;, '&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_26"&gt;TableName&lt;/span&gt;.&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_27"&gt;ColumnName&lt;/span&gt;'&lt;br /&gt;&lt;br /&gt;NOTE : ONLY ONE RULE CAN BE APPLIED TO A COLUMN OR A &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_28"&gt;UDT&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;The &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_29"&gt;Exising&lt;/span&gt; Rule , If any &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_30"&gt;willl&lt;/span&gt; be overwritten.&lt;br /&gt;&lt;br /&gt;SP_&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_31"&gt;UNBINDRULE&lt;/span&gt; is used to remove a rule from a Column or &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_32"&gt;UDT&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Syntax&lt;br /&gt;&lt;br /&gt;Sp_&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_33"&gt;UNBINDRULE&lt;/span&gt;&lt;br /&gt;               [@objname =] 'object_name'&lt;br /&gt;               [, [@futureonly =] '&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_34"&gt;futureonly&lt;/span&gt;_flag']&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Arguments,&lt;br /&gt;&lt;br /&gt;1) Object Name&lt;br /&gt;                                  Name of the Table Column or &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_35"&gt;UDT&lt;/span&gt;.&lt;br /&gt;2) &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_36"&gt;futureonly&lt;/span&gt;&lt;br /&gt;                                  If it is set , then Existing columns of the type '&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_37"&gt;UDT&lt;/span&gt;' &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_38"&gt;wil&lt;/span&gt; not loose the Constraint, but future &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_39"&gt;UDT&lt;/span&gt; columns will not have this Constraint.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;DROP RULE &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_40"&gt;RuleName&lt;/span&gt; : is used to drop the Rule.&lt;br /&gt;&lt;br /&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_41"&gt;RAISERROR&lt;/span&gt; : &lt;br /&gt;             Returns a user-defined error message and sets a system flag to record that an error has occurred. The client can either retrieve an entry from the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_42"&gt;sysmessages&lt;/span&gt; table or build a message dynamically with user-specified severity and state information.&lt;br /&gt;&lt;br /&gt;Will post more information about the same in my next post....&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-4225025751055100342?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/4225025751055100342/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=4225025751055100342' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/4225025751055100342'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/4225025751055100342'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2007/06/sql-server-under-hood.html' title='Sql Server : Under the HOod'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-6585064542058064687</id><published>2007-06-19T05:29:00.000-07:00</published><updated>2007-06-19T06:27:38.748-07:00</updated><title type='text'>Playing with OOPS</title><content type='html'>I have 3 classes&lt;br /&gt;&lt;br /&gt;class A, B and C.&lt;br /&gt;&lt;br /&gt;In class A and class B, i've a data member : public int i;&lt;br /&gt;&lt;br /&gt;ill inherit class B from A.&lt;br /&gt;&lt;br /&gt;class B : A&lt;br /&gt;&lt;br /&gt;After this, i've two variables "i" having the same name.&lt;br /&gt;&lt;br /&gt;Now , can i access both the values just one using one object ??&lt;br /&gt;&lt;br /&gt;I can use base in C# and mybase in vb.Net, but i dont want to use them in constructor..&lt;br /&gt;&lt;br /&gt;If, i have one more class like this..&lt;br /&gt;&lt;br /&gt;class C : B&lt;br /&gt;&lt;br /&gt;Then, in class C, can i create a single object, using which i can access both the base class A and Derived Class B's data member "i" ?&lt;br /&gt;&lt;br /&gt;Stilll looking for an answer/solution.&lt;br /&gt;&lt;br /&gt;Hope i find one soooner...........&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-6585064542058064687?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/6585064542058064687/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=6585064542058064687' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/6585064542058064687'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/6585064542058064687'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2007/06/playing-with-oops.html' title='Playing with OOPS'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-7133521015113009132</id><published>2007-06-11T00:27:00.000-07:00</published><updated>2007-06-11T02:05:46.934-07:00</updated><title type='text'>Sql Server 2000 : Maximum Capacity Specifications</title><content type='html'>Found this piece of info in &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;MSDN&lt;/span&gt; !&lt;br /&gt;&lt;br /&gt;The Maximum Capacity Specifications in &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;Sql&lt;/span&gt; Server 2000/97&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Columns per SELECT statement : 4096&lt;br /&gt;&lt;br /&gt;Columns per INSERT statement : 1024&lt;br /&gt;&lt;br /&gt;Nested stored procedure levels :    32&lt;br /&gt;&lt;br /&gt;Nested &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;subqueries&lt;/span&gt;  :                         32&lt;br /&gt;&lt;br /&gt;Nested trigger levels :                      32&lt;br /&gt;&lt;br /&gt;Parameters per stored procedure  1024&lt;br /&gt;&lt;br /&gt;Tables per SELECT statement       256&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;The sum of the number of all these objects in a database cannot exceed 2,147,483,647.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Check out more information @&lt;br /&gt;&lt;br /&gt;&lt;a href="http://msdn2.microsoft.com/en-us/library/aa933149(SQL.80).aspx"&gt;http://msdn2.microsoft.com/en-us/library/aa933149(SQL.80).aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;Cheerz&lt;/span&gt; !&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-7133521015113009132?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/7133521015113009132/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=7133521015113009132' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/7133521015113009132'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/7133521015113009132'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2007/06/sql-server-2000-maximum-capacity.html' title='Sql Server 2000 : Maximum Capacity Specifications'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-8332677236406892834</id><published>2007-03-23T03:19:00.001-07:00</published><updated>2007-03-23T03:19:34.510-07:00</updated><title type='text'>Test Blog !</title><content type='html'>Test blog ! &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-8332677236406892834?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/8332677236406892834/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=8332677236406892834' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/8332677236406892834'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/8332677236406892834'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2007/03/test-blog.html' title='Test Blog !'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-8290873614554534074</id><published>2007-03-14T06:56:00.000-07:00</published><updated>2007-03-14T07:12:29.066-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Custom Publisher'/><title type='text'>EHAB Continued....</title><content type='html'>Whole day was working on EHAB and finally implemented a custom publisher !&lt;br /&gt;&lt;br /&gt;Create the Custom Publisher Class&lt;br /&gt;&lt;br /&gt;           1)        In the Exception Application block, i added a VB class called "CustomPublisher"&lt;br /&gt;           2)        Code for the class file would go like this...&lt;br /&gt;&lt;br /&gt;                               &lt;br /&gt;Imports Microsoft.ApplicationBlocks.ExceptionManagement&lt;br /&gt;Imports Microsoft.ApplicationBlocks.Data&lt;br /&gt;Imports System.Web&lt;br /&gt;Imports System.Data.SqlClient&lt;br /&gt;Imports System.Data&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Public Class CustomPublisher&lt;br /&gt;Implements IExceptionPublisher&lt;br /&gt;&lt;br /&gt;Public Sub Publish(ByVal exception As System.Exception, ByVal additionalInfo As NameValueCollection, ByVal configSettings As NameValueCollection) Implements IExceptionPublisher.Publish&lt;br /&gt;&lt;br /&gt;Try&lt;br /&gt;               Dim strConn As String&lt;br /&gt;               strConn = ConfigurationSettings.AppSettings.Get("ConnStr").ToString()&lt;br /&gt;-- Some how get the Conn string&lt;br /&gt;               SqlHelper.ExecuteNonQuery(strConn,CommandType.StoredProcedure,"usp_InsertException")&lt;br /&gt;-- Some Stored proc to insert ur exception...&lt;br /&gt;               Catch ex As exception&lt;br /&gt;-- Do something to catch the exception here,  outta scope of EHAB&lt;br /&gt;               End Try&lt;br /&gt;End Sub&lt;br /&gt;End Class&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;3)              Configure the Web.config file...&lt;br /&gt;&lt;br /&gt;                          the contents shud go like this....&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;                &lt;br /&gt;&lt;configsections&gt;&lt;br /&gt;&lt;section name="exceptionManagement" type="Microsoft.ApplicationBlocks.ExceptionManagement.ExceptionManagerSectionHandler, Microsoft.ApplicationBlocks.ExceptionManagement"&gt;&lt;br /&gt;&lt;/configsections&gt;&lt;br /&gt;&lt;br /&gt;&lt;exceptionmanagement mode="on"&gt;&lt;br /&gt;&lt;publisher assembly="Microsoft.ApplicationBlocks.ExceptionManagement" type="Microsoft.ApplicationBlocks.ExceptionManagement.CustomPublisher" filename="C:\CustomExceptions.txt"&gt;&lt;br /&gt;&lt;/exceptionmanagement&gt;&lt;br /&gt;&lt;br /&gt;Now, note that the assembly name must be the Name of the Assembly where the project is deployed and type should be the class name which overrides the Publish method.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Now, in the project, where ever therez an exception, all we need to do is call the method&lt;br /&gt;&lt;br /&gt;                         ExceptionManager.Publish(ex)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;The rest is taken care by EHAB.&lt;br /&gt;&lt;br /&gt;Wasted a couple of hours working on App.config file..&lt;br /&gt;&lt;br /&gt;Realized that App.Config file is for Windows Applications and&lt;br /&gt;Web.config file is for Web Application...&lt;br /&gt;&lt;br /&gt;More to Come on the same...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-8290873614554534074?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/8290873614554534074/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=8290873614554534074' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/8290873614554534074'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/8290873614554534074'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2007/03/ehab-continued.html' title='EHAB Continued....'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-8694182755267286555</id><published>2007-03-13T02:51:00.000-07:00</published><updated>2007-03-13T03:04:56.114-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Exception Handling Application Block&apos;s Exceptions'/><title type='text'></title><content type='html'>I was playing around with Exception Handling Application Block ( EHAB) !&lt;br /&gt;&lt;br /&gt;I created a dummy ASP.Net Web Application.&lt;br /&gt;&lt;br /&gt;I added the Reference of EHAB to the Project.&lt;br /&gt;&lt;br /&gt;I build the project, i got an error saying&lt;br /&gt;&lt;br /&gt;                    "type IExceptionPublisher is not defined "&lt;br /&gt;&lt;br /&gt;I build the EHAB and added its reference again.&lt;br /&gt;&lt;br /&gt;Now, i build the project and the error was gone.&lt;br /&gt;&lt;br /&gt;Now, i wrote a code that would rise an exception and i wanted that to be recorded using EHAB.&lt;br /&gt;&lt;br /&gt;I ran the project and i got an un expected exception saying&lt;br /&gt;&lt;br /&gt;              "Requested registry access is not allowed"&lt;br /&gt;&lt;br /&gt;I googled this exception and found some info about&lt;br /&gt;&lt;br /&gt;Thanks to Mr. Brono from UK..&lt;br /&gt;&lt;br /&gt;This is what he had posted in his blog...&lt;br /&gt;&lt;br /&gt;Requested Registry Access is not allowed&lt;br /&gt;SOLUTION IS AS FOLLOW (THIS SOLUTION IS FOR DEVELOPMENT ENVIRONMENT ONLY):&lt;br /&gt;&lt;br /&gt;1. Give the ASPNET user permission to read the Security eventlog registry entry.Run regedt32 Navigate to the following key:HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Eventlog\Security Right click on this entry and select Permissions Add the ASPNET user Give it Read permission&lt;br /&gt;&lt;br /&gt;2. Change settings in machine.config fileRun ExplorerNavigate to WINDOWS or WINNT folderOpen Microsoft.NET folderOpen Framework folderOpen v1.1.4322 folder (folder name may be different, depending on what dotnet version is installed)Open CONFIG folderOpen machine.config file using notepad (make a backup of this file first)Locate processmodel tag (approx. at line 441)Locate userName="machine" (approx. at line 452)Change it to userName="SYSTEM"Save and close the fileClose Explorer&lt;br /&gt;&lt;br /&gt;3. Restart IIS Run IISReset&lt;br /&gt;&lt;br /&gt;Production Solution&lt;br /&gt;&lt;br /&gt;Go to the application pool and select IDENTITY leave it Network ServiceGo to the registry it is accessing and select the permissionAdd the NETWORK SERVICE user to it&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;After making the above changes... I ran the project again and found one more exception sayin...&lt;br /&gt;&lt;br /&gt;         "Event Log Full"&lt;br /&gt;I had to make the event log empty... Googled again.&lt;br /&gt;&lt;br /&gt;Run the command "eventvwr.msc" from Windows Start&lt;br /&gt;&lt;br /&gt;Right Click on the Application and say clear all events.&lt;br /&gt;&lt;br /&gt;Now the event log was empty.&lt;br /&gt;&lt;br /&gt;I ran the application again and found the exception Published in the event log.&lt;br /&gt;&lt;br /&gt;More to come on EHAB.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-8694182755267286555?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/8694182755267286555/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=8694182755267286555' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/8694182755267286555'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/8694182755267286555'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2007/03/i-was-playing-around-with-exception.html' title=''/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4398024747633199956.post-2124176596474380598</id><published>2007-03-01T04:01:00.000-08:00</published><updated>2007-03-01T04:02:33.528-08:00</updated><title type='text'>Check this one out....</title><content type='html'>&lt;a href="http://www.tiddlywiki.com/"&gt;http://www.tiddlywiki.com/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;A new era of Web Pages...&lt;br /&gt;&lt;br /&gt;Can it change the definition of Dynamic Web Pages....&lt;br /&gt;&lt;br /&gt;Gotta wait n seee. :)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4398024747633199956-2124176596474380598?l=sandeepunleashed.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sandeepunleashed.blogspot.com/feeds/2124176596474380598/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4398024747633199956&amp;postID=2124176596474380598' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/2124176596474380598'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4398024747633199956/posts/default/2124176596474380598'/><link rel='alternate' type='text/html' href='http://sandeepunleashed.blogspot.com/2007/03/check-this-one-out.html' title='Check this one out....'/><author><name>Sandy</name><uri>http://www.blogger.com/profile/05338120488987971677</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
