SELECT * FROM
( SELECT 'one' AS TableName, 'display' AS FieldName, display_name AS Search FROM One AS O1
UNION
SELECT 'one', 'name', name FROM One AS O2
UNION
SELECT 'two', 'display', display_name FROM Two AS T1
UNION
SELECT 'two', 'name', name FROM Two AS T2
UNION
SELECT 'three', 'display', display_name FROM Three AS T3
UNION
SELECT 'three', 'name', name FROM Three AS T4) AS TableSearch
WHERE Search = 'Word'
update TeamMembers set name =
нет значения. Для каждого поля нужно писать отдельный подзапрос.DECLARE @ID_TeamMembers INT
SELECT @ID_TeamMembers = ID FROM TeamMembers WHERE …
IF @ID_TeamMembers IS NULL
INSERT INTO TeamMembers …
SET @ID_TeamMembers = IDENT_CURRENT( 'TeamMembers' ) -- чтобы не был NULL, может нужно будет
ELSE
UPDATE TeamMembers SET … WHERE ( ID = @ID_TeamMembers )