The problem is that some magic quotes are enabled. Magic quotes (all types) are bad and should always be disabled.
MSSQL doesn't use backslash to escape strings anyway. So magic quotes are even less useful than they would be anyway (if that were even possible!).
Strings going into the database should either be escaped appropriately (Which does not mean addslashes) OR, for preference, passed as a parameter to a parameterised query.
Generally speaking, if you're using addslashes or stripslashes, you're doing something wrong as neither function is useful under any circumstances.
Likewise, magic quotes are never helpful, turn them all off permanently. I put checks in all my applications to ensure that magic quotes are off (and crash out of they are on) to ensure that they don't cause data corruption (the kind you're describing).
Mark