How to Concatenate Strings in SQL Server
Last updated July 25, 2026 · By the SaturnSQL team
The + operator joins strings but returns NULL if any operand is NULL. CONCAT() treats NULLs as empty strings and converts non-string types automatically, and CONCAT_WS() (2017+) inserts a separator between values.
SELECT
first_name + ' ' + last_name AS plus_operator,
CONCAT(first_name, ' ', last_name) AS concat_fn,
CONCAT_WS(', ', city, region, country) AS location
FROM customers;With +, one NULL column makes the whole result NULL, and mixing in a number raises a conversion error. CONCAT sidesteps both, and CONCAT_WS also skips NULL values entirely rather than leaving doubled separators.
Run this in SaturnSQL
SaturnSQL is a browser-based SQL editor for teams: shared query library, schema-aware autocomplete, and scheduled exports to Google Sheets and Slack.
Try it free