Microsoft
Software
Hardware
Network
Question : How to use "IsNull" with varchar datatype?
can anybody please explain what the second line of code is doing in the following statements.
I am trying to use some existing functionality, but I am not getting how to interpret this.
@GMTOffset varchar(5)
if len(ltrim(isNull(@GMTOffse
t,''))) = 0 set @GMTOffset = null
Thanks in advance!
Answer : How to use "IsNull" with varchar datatype?
Sure...it trims any spaces from the left and right of the variable and then looks at the length of the value in the variable. The ISNULL function puts an emptry string in place of a null valued variable.
Random Solutions
Restrict value to field - unique but allow certain values
Multiple Asset tracking per month / Per year
Automatically update Org Chart when DB is updated
RAID config options for SQL Server 2008
Basic Form Question
Is there a way of reverting from Windows 7 back to Windows XP? I have a Windows.old folder that has saved all of the main Windows XP folders
PowerPoint Crashes on PasteSpecial DataType:=ppPasteOLEObect
How do I add some records in a query field?
Import a TXT file with >255 fields into Access 2003
How to configure VPN access on SBS 2008