You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

29 lines
1.5 KiB

USE [FastMoneyPro_Remit]
GO
/****** Object: UserDefinedFunction [dbo].[GetBranchName] Script Date: 12/7/2023 4:56:16 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
-- =============================================
-- Author: <Author,,Name>
-- Create date: <Create Date, ,>
-- Description: <Description, ,>
-- =============================================
ALTER function [dbo].[GetBranchName](@ID int)
returns char(1000)
as
begin
declare @Full_Name as varchar(500)
if @ID is null or @ID=0 or @ID=''
begin
set @Full_Name='All Agents'
return @Full_Name;
end
set @Full_Name = ( select BRANCH_NAME from API_BANK_BRANCH_LIST with (nolock)
WHERE BRANCH_ID = @ID)
return @Full_Name
end