Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 truncate a value to fit in a variable

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2001-05-02 : 09:12:06
theo leijen writes "I've made a update statement which has to fill a variable. But when the result is larger than the size of the field, i get an error message.

How can i let SQL truncate the result to 50 characters?

This is the statement:

UPDATE Employees
set BdgNaam = BadgeNumber | | '' - '' | | Naam | | '', '' | | VoorNaam | | '' '' | | Tussenvoegsel


Thank you."
   

- Advertisement -