Prev: Query Help for Newb
Next: How can I connect from SSMS
From: LuisM on 13 Jul 2010 08:05 Hi I'm using the following expression to join two text fields where one of them should be null: table1.name1 & ' ' & isnull(table1.name2,'') as name But it reports this error: Data types nvarchar and nvarchar ar incompatible with the boolean AND operator. Thanks LAM
From: Scott Morris on 13 Jul 2010 08:47 "LuisM" <luisantony&@hotmail.com> wrote in message news:%23fVNwOoILHA.4248(a)TK2MSFTNGP02.phx.gbl... > Hi > I'm using the following expression to join two text fields where one of > them should be null: table1.name1 & ' ' & isnull(table1.name2,'') as name > But it reports this error: Data types nvarchar and nvarchar ar > incompatible with the boolean AND operator. Go to BOL (online help) and look up "string concatenation operators" in the index.
From: LuisM on 13 Jul 2010 09:04 Thanks, the right operator is + instead of & LAM "Scott Morris" <bogus(a)bogus.com> escribi� en el mensaje de noticias:eEfDbmoILHA.1016(a)TK2MSFTNGP06.phx.gbl... > "LuisM" <luisantony&@hotmail.com> wrote in message > news:%23fVNwOoILHA.4248(a)TK2MSFTNGP02.phx.gbl... >> Hi >> I'm using the following expression to join two text fields where one of >> them should be null: table1.name1 & ' ' & isnull(table1.name2,'') as name >> But it reports this error: Data types nvarchar and nvarchar ar >> incompatible with the boolean AND operator. > > Go to BOL (online help) and look up "string concatenation operators" in > the index. >
|
Pages: 1 Prev: Query Help for Newb Next: How can I connect from SSMS |