
[dbo].[GetAccountingBankAccounts]
CREATE PROCEDURE [dbo].[GetAccountingBankAccounts]
@inBranchPriKey int
as
set nocount on
select
AccountingBankAccount.AccountingBankAccountId,
[Description] = AccountingBankAccount.[Description],
AccountingBankAccount.[Hidden]
from AccountingBankAccount
inner join XLedgerBankAccount on XLedgerBankAccount.AccountingBankAccountFid = AccountingBankAccount.AccountingBankAccountId
inner join XLedgerBranchObjectValue on XLedgerBranchObjectValue.XLedgerCompanyFid = XLedgerBankAccount.XLedgerCompanyFid
where XLedgerBranchObjectValue.BranchFid = @inBranchPriKey
order by AccountingBankAccount.[Description]
GO
GRANT EXECUTE ON [dbo].[GetAccountingBankAccounts] TO [MssExec]
GO