Function at 0x451e70
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c0
mov eax, dword [0x5005d0]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
push edi
mov dword [ebp - 0x4bc], eax
mov eax, dword [ebp + 0x10]
xor ebx, ebx
push 0x3f
mov dword [ebp - 0x4b8], eax
lea eax, [ebp - 0xa3]
mov edi, ecx
push ebx
push eax
mov dword [ebp - 0x4c0], edi
mov byte [ebp - 0xa4], bl
call fcn.004a7110
add esp, 0xc
mov esi, 0x3ff
push esi
lea eax, [ebp - 0x4a3]
push ebx
push eax
mov byte [ebp - 0x4a4], bl
call fcn.004a7110
add esp, 0xc
cmp edi, ebx
je 0x451edc
mov dword [edi], ebx
mov eax, dword [ebp - 0x4bc]
cmp eax, ebx
je 0x451ee8
mov dword [eax], ebx
mov eax, dword [ebp - 0x4b8]
cmp eax, ebx
je 0x451ef4
mov dword [eax], ebx
call fcn.0040ee7c
test eax, eax
jne 0x451f04
xor eax, eax
jmp 0x452125
xor eax, eax
call fcn.0044e06e
test eax, eax
jne 0x451efd
push ebx
call fcn.0044eba5
pop ecx
mov ecx, eax
cmp ecx, ebx
mov dword [ebp - 0x4a8], ecx
je 0x451efd
call fcn.0044ee2c
cmp eax, ebx
jle 0x451f44
push eax
push str._AND_LOC_d
lea eax, [ebp - 0xa4]
push 0x40
push eax
call fcn.00476e0a
add esp, 0x10
jmp 0x451f4f
lea eax, [ebp - 0xa4]
call fcn.004757d4
lea eax, [ebp - 0xa4]
push eax
movzx eax, byte [ebp + 0xb]
push eax
movzx eax, byte [ebp + 0xa]
push eax
movzx eax, word [ebp + 8]
push eax
push str.SELECT_REF_TENDER_TYPE_ID_PAYMENT_AMOUNT_DISCOUNT_TAKEN_REF_AR_PAYMENT_ORIGINATION_CD_FROM_AR_PAYMENT_WHERE_DATE_PAYMENT_ENTRY_DATE__04d__02d__02d_s_AND__REF_AR_PAYMENT_ORIGINATION_CDN_OR_REF_AR_PAYMENT_ORIGINATION_CDC_OR_REF_AR_PAYMENT_ORIGINATION_CDP_
push dword [ebp - 0x4a8]
mov dword [ebp - 0x4b0], ebx
mov dword [ebp - 0x4b4], ebx
mov dword [ebp - 0x4ac], ebx
call fcn.0044dda3
add esp, 0x18
test eax, eax
je 0x4520e5
xor eax, eax
mov byte [ebp - 0x20], bl
lea edi, [ebp - 0x1f]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
xor eax, eax
push 7
pop ecx
mov byte [ebp - 0x40], bl
lea edi, [ebp - 0x3f]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
push 7
xor eax, eax
pop ecx
mov byte [ebp - 0x60], bl
lea edi, [ebp - 0x5f]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
xor eax, eax
mov byte [ebp - 0x14], bl
lea edi, [ebp - 0x13]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosw word es:[edi], ax
push 4
push 9
stosb byte es:[edi], al
push esi
lea eax, [ebp - 0x4a4]
push eax
push dword [ebp - 0x4a8]
xor edi, edi
call fcn.0044de8e
add esp, 0x14
test eax, eax
je 0x4520da
mov esi, 0x4c7f6c
cmp edi, 0x8ae
jge 0x4520da
push 0xb
lea eax, [ebp - 0x20]
push eax
push ebx
push esi
lea eax, [ebp - 0x4a4]
call fcn.0047706a
push 0x1f
lea eax, [ebp - 0x40]
push eax
push 1
push esi
lea eax, [ebp - 0x4a4]
call fcn.0047706a
push 0x1f
lea eax, [ebp - 0x60]
push eax
push 2
push esi
lea eax, [ebp - 0x4a4]
call fcn.0047706a
push 0xb
lea eax, [ebp - 0x14]
push eax
push 3
push esi
lea eax, [ebp - 0x4a4]
call fcn.0047706a
movsx eax, byte [ebp - 0x14]
add esp, 0x40
call fcn.004756d4
mov byte [ebp - 0x14], al
lea eax, [ebp - 0x20]
push eax
call fcn.004a8d7f
pop ecx
call fcn.004554d6
push eax
call fcn.00457905
add esp, 4
test eax, eax
jne 0x4520b3
cmp byte [ebp - 0x14], 0x43
je 0x4520a5
cmp byte [ebp - 0x14], 0x4e
je 0x4520a5
lea eax, [ebp - 0x40]
call fcn.0043a4ed
add dword [ebp - 0x4b0], eax
lea eax, [ebp - 0x60]
call fcn.0043a4ed
add dword [ebp - 0x4b4], eax
jmp 0x4520b3
lea eax, [ebp - 0x40]
call fcn.0043a4ed
add dword [ebp - 0x4ac], eax
push 4
push 9
push 0x3ff
lea eax, [ebp - 0x4a4]
push eax
push dword [ebp - 0x4a8]
inc edi
call fcn.0044de8e
add esp, 0x14
test eax, eax
jne 0x451ff5
mov edi, dword [ebp - 0x4c0]
xor esi, esi
inc esi
jmp 0x4520e7
xor esi, esi
push dword [ebp - 0x4a8]
call fcn.0044db5e
cmp edi, ebx
pop ecx
je 0x4520ff
mov eax, dword [ebp - 0x4b0]
mov dword [edi], eax
mov eax, dword [ebp - 0x4bc]
cmp eax, ebx
je 0x452111
mov ecx, dword [ebp - 0x4b4]
mov dword [eax], ecx
mov eax, dword [ebp - 0x4b8]
cmp eax, ebx
je 0x452123
mov ecx, dword [ebp - 0x4ac]
mov dword [eax], ecx
mov eax, esi
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004a69f5
leave
ret