Sql string length

This article is tagged with: Sql string length and mysql

sql string length

-- Relevant for SQL-Oracle only
-- syntax
LENGTH(<your-string>)
-- example
LENGTH('CountCharacters') -- OUTPUT: 15
123456789012345
-- example with query
SELECT 'CountCharacters',LENGTH('CountCharacters')
FROM DUAL;
-- OUTPUT: CountCharacters, 15</your-string>

sql length

-- Relevant for MS SQL (SQL Server)
LEN('string')

This article is tagged with: Sql string length and mysql