IF EXISTS ( SELECT * 
            FROM   sysobjects 
            WHERE  id = object_id(N'dbo.CP_SCA_Clientes_Huellas') 
                   and OBJECTPROPERTY(id, N'IsProcedure') = 1 )
BEGIN
    DROP PROCEDURE dbo.CP_SCA_Clientes_Huellas
END
GO

CREATE PROCEDURE dbo.CP_SCA_Clientes_Huellas @pId_Cliente	INT
AS 

CREATE TABLE #huellas
(Nro	SMALLINT,
Huella	VARCHAR(MAX))

INSERT INTO #huellas
SELECT 
Nro,
REPLACE(CAST(CONVERT(VARCHAR(MAX), Huella, 2) AS CHAR(768)), '', '0') 
FROM Clientes_HD 
WHERE 
Id_Cliente = @pId_Cliente

SELECT * FROM #huellas

DROP TABLE #huellas