SQL: Is REPLICATE in SQL Server not replicating enough?
Even though I’ve worked with SQL Server for what feels like forever, I still constantly trick myself up with T-SQL commands that give me output that’s different to what I was expecting. This week, it was REPLICATE.
What should the output of the following statement be?
SELECT REPLICATE(‘Hello’, 10000);
If you said the word Hello repeated 10,000 times, or didn’t know at all, read on.
The clue comes if I execute the following statement:
2019-03-29