SELECT IIF(u IN(1,s),REPLICATE(s,s),CONCAT(s,REPLICATE(' ...

0

Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow

Q&A for professional and enthusiast programmers

SELECT IIF(u IN(1,s),REPLICATE(s,s),CONCAT(s,REPLICATE(' ',s-2*LEN(s)),s))
FROM(SELECT 6s)z CROSS APPLY(SELECT TOP(s)ROW_NUMBER()OVER(ORDER BY 1/0)u FROM sys.messages)v

Enter Parameters

Options:
Switch to meta site
loading Hold tight while we fetch your results