SET QUOTED_IDENTIFIER ON
GO
SET ANSI_NULLS ON
GO
CREATE PROCEDURE [dbo].[p_pol_policies_lst]
    @policy_id int
AS 
	set nocount on

	select	a.act_actor_id,
			a.act_internal_reference,
			p.*
	from	pol_policies p
			inner join act_actors a on a.act_actor_id = p.pol_client_id
	where	@policy_id = 0 or p.pol_policy_id = @policy_id
	
			
			

GO
