I want to write a query kind of like this:
CREATE PROCEDURE DupFinder
@FirstName varchar(20),
@LastName varchar(20)
AS
SELECT CustId
FROM Cust c
WHERE [dbo].[fn_MatchConfidence](@FirstName + ' ' + @LastName,
[dbo].fn_createCustHash (CustId)) > .8
Running the fn_MatchCondifence User-Defined Function (which takes two varchars and returns a number) over the entire Cust table. CreateCustHash just makes a string of FirstName and LastName with a space in the middle.
How can I do this?