Posted by: jwalin on: March 25, 2009
http://interviews.dotnetthread.com/2009/02/making-gridview-rows-or-individual.html
Posted by: jwalin on: March 5, 2009
Thankx to By Joshua A. WalkerTESTING:
SELECT dbo.DBA_fnAddLeadingZeros(2457,6)
Result: ‘002457”
***************************************************************************/
CREATE FUNCTION [dbo].[DBA_fnAddLeadingZeros](@Int INT, @TotalLength INT)
RETURNS VARCHAR(2000)
AS
BEGIN
DECLARE @Return VARCHAR(2000)
/************************************************************************
–IF @TotalLength > 100 SELECT @TotalLength = 100
SELECT @Return = replicate(‘0′,@TotalLength) + CAST(@Int AS VARCHAR)
RETURN RIGHT(@Return,@TotalLength)
END
Happy Programming !!!!
Posted by: jwalin on: March 3, 2009
If you want to delete all the records from the all the tables in database you might consider Delete Or Trancate command as both delete all the records from the tables. However it depends on ‘Constraint’ and delete records from one table at a time. But here is the code which delete the records from [...]