Thursday, June 13, 2013

How to use user-Defined Function

CREATE FUNCTION [dbo].[GenerateIntegers] ( @MaxValue INT )
RETURNS @Integers TABLE ( [IntValue] INT )
AS
BEGIN
    DECLARE @Index    INT
    SET @Index = 0
    WHILE @Index <= @MaxValue
    BEGIN
        INSERT INTO @Integers ( [IntValue] ) VALUES ( @Index )
        SET @Index = @Index + 1
    END

    RETURN
END
GO


Description

The user-defined function is quite straight-forward.  It simply inserts into the return TABLE variable (@Integers) the integer values from 1 to the maximum integer value supplied in the parameter using a WHILE loop.  If the value supplied in the parameter is less than 1, then the table returned will not contain any records.

To use this function, you can simply issue a simple SELECT statement and using this in the FROM clause of the SELECT, as follows:

SELECT * FROM [dbo].[GenerateIntegers] ( 1001 )

Tuesday, June 11, 2013

List of Free SEO Friendly Directories

http://21stguru.com    
http://addalinkdirectory.com    
http://bestsubmitdirectory.com
http://carefullypicked.com    
http://directorycave.com    
http://directpr.org    
http://dirtree.com    
http://elektronickits.com    
http://fastfiredirectory.com    
http://featuredinc.com    
http://freedofollowdirectory.org    
http://freelanddirectory.com    
http://gainesvillesbest.com    
http://glitterdirectory.com    
http://intermagnetusa.org    
http://links.kozolec.net    
http://m-directory.com    
http://masterseodirectory.com    
http://myonlinewebdirectory.org    
http://online-web-directory.com    
http://prboostdirectory.com    
http://reppinbelizean.com    
http://reservelinks.info    
http://searchwebdirectory.net    
http://shamrockdirectory.com




Note: More information visit: http://www.directorymaximizer.com/seo-friendly-directories.php

Sunday, June 09, 2013

Server Error -- System.Web.HttpException: Unable to validate data.

use machine key under system.web in web.config file to rectify this error

<system.web>
    <machineKey validationKey="AutoGenerate,IsolateApps" decryptionKey="AutoGenerate,IsolateApps" validation="3DES" decryption="3DES"/>
</system.web>