What are the difference between data length and length in
SQL Server-2008?
Answer Posted / bindu
The DATALENGTH function counts both trailing spaces and preceeding spaces when calculating the length of the expression.
The DATALENGTH function will return NULL, if the expression is NULL.
The LEN function does NOT count trailing spaces at the end of the string when calculating the length of the string.
The LEN function does count spaces at the start of the string when calculating the length of the string.
The LEN function will return NULL, if the string is NULL.
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
Write the syntax for stuff function in an sql server?
How to use column default values in insert statements in ms sql server?
what are the different ways to return the rowcount of a table?
How each E-R model constructs can be mapped to the relational model?
How to disconnect from a sql server using mssql_close()?
What is attribute hierarchy? : sql server analysis services, ssas
What is merge statement?
How do I completely remove sql server instance?
Write a query for primary key constraint with identity key word?
Can we use pragma autonomous_transaction in trigger?
What is a raid and what are different types of raid configurations?
What is inner join in sql server joins?
How to send email from database?
what is the information that can be stored inside a bit column? : Sql server database administration
How do you open a cluster administrator?