Can someone explain to me what logic there is to enabling ANSI padding by default in SQL server.
Where the two code snippets below return true
if len(' ') = len('') begin
print 'true'
end
else begin
print 'false'
end
if ' ' = '' begin
print 'true'
end
else begin
print 'false'
end
EDIT: I do not care about that you can turn it off. Does anyone know why it is on? Is it a database design decision? Is it a database optimisation? What are the positives of this being used? It certainly doesn’t make much sense to me – all I see are negatives.
To be compliant with the ANSI/ISO SQL-92 specification: