CONCAT String with NULL – Changing default behavior of SSMS
We are on Sybase ASE and are in the processing migrating to MS SQL Server.
In Sybase ASE
select null + ‘DBMS’ ==> DBMS
In MS SQL Server (with SSMS)
In SSMS QUERY Options has by default “CONCAT_NULL_YIELDS_NULL” set to ON.
select null + ‘DBMS’ ==> NULL
If we override every session with “SET CONCAT_NULL_YIELDS_NULL” to OFF then we get
select null + ‘DBMS’ ==> DBMSWe are looking for changing the default behavior of SSMS. Wondering what is the right means of accomplishing this. Though the example here is about SSMS, we want all clients to have CONCAT_NULL_YIELDS_NULL to be turned off. We do not know the default behavior of different drivers yet.
Thanks for your help!
We are on Sybase ASE and are in the processing migrating to MS SQL Server. In Sybase ASE select null + ‘DBMS’ ==> DBMSIn MS SQL Server (with SSMS)In SSMS QUERY Options has by default “CONCAT_NULL_YIELDS_NULL” set to ON.select null + ‘DBMS’ ==> NULL If we override every session with “SET CONCAT_NULL_YIELDS_NULL” to OFF then we getselect null + ‘DBMS’ ==> DBMSWe are looking for changing the default behavior of SSMS. Wondering what is the right means of accomplishing this. Though the example here is about SSMS, we want all clients to have CONCAT_NULL_YIELDS_NULL to be turned off. We do not know the default behavior of different drivers yet. Thanks for your help! Read More