Teradata String Manipulation - Remove last character
Purpose:\nCreate a query that eliminates the middle Initial
Example
\n\nName\nSmith, John A\nJane, Mary S\n
\n\nI would like an output such as this:
\n\nName\nSmith, John\nJane, Mary\n
\n\nSolution:
SELECT SUBSTR('SMITH, JOHN A', 1, CHAR_LENGTH(NAME)-1);\n
nVector
posted onEnjoy great content like this and a lot more !
Signup for a free account to write a post / comment / upvote posts. Its simple and takes less than 5 seconds
Post Comment