ALTER PROCEDURE [dbo].[a_sel_numRegistrosXtabla_m]
	@p_filtro as varchar (max) = '1=1',
	@p_tabla varchar(100) = '',
	@p_eid as varchar(50) = ''
AS
BEGIN
declare @v_query as varchar (max)
set @v_query ='select count(*) as cantidad  
FROM [view_'+ @p_tabla +'] 
WHERE (' + @p_filtro + ') AND active=1 AND (eid like '''+@p_eid+'%'+''' )'
exec (@v_query)
END
