CREATE proc [C244570_marriage].[sp_getpersonaldetails]
@custid nvarchar(max)=NULL,
@Gender nvarchar(max)=NULL
as
begin
if (@custid is not null)
begin
select * from personalinfo where CustomerId=@custid
end
else
if (@Gender is not null)
begin
select * from personalinfo where Gender=@Gender
end
end