Function at 0x4098e0
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4105e6
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x1d4
push ebx
push esi
mov esi, ecx
push edi
lea ecx, [ebp - 0x44]
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x2c], esi
call fcn.0040bb90
xor ebx, ebx
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], ebx
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 1
call sub.MFC42.DLL_CString::CString
lea eax, [ebp - 0x28]
mov byte [ebp - 4], 2
push eax
call sub.MFC42.DLL_AfxVariantInit
mov ecx, dword [esi + 0x4c8]
mov byte [ebp - 4], 3
push ecx
lea ecx, [ebp - 0x100]
call fcn.0040f654
mov edx, dword [esi + 0x4c8]
lea ecx, [ebp - 0x198]
push edx
mov byte [ebp - 4], 4
call fcn.0040f654
mov esi, dword [ebp + 8]
mov byte [ebp - 4], 5
cmp esi, ebx
je 0x409d7a
push esi
lea ecx, [ebp - 0x14]
push str.SELECT__FROM_lgfh_tab_WHERE_lgdm_s
push ecx
call sub.MFC42.DLL_CString::Format
add esp, 0xc
lea edx, [ebp - 0x18]
push esi
push str.SELECT__FROM_lg_tab_WHERE_lg_code_s
push edx
call sub.MFC42.DLL_CString::Format
mov ecx, 0x11
xor eax, eax
lea edi, [ebp - 0x1e0]
add esp, 0xc
rep stosd dword es:[edi], eax
stosb byte es:[edi], al
lea eax, [ebp - 0x1e0]
push esi
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyA]
push eax
call esi
mov ecx, dword [ebp - 0x18]
push ebx
push ecx
push 0xffffffffffffffff
lea ecx, [ebp - 0x198]
call sub.MFC42.DLL_CDaoRecordset::Open
lea ecx, [ebp - 0x198]
mov byte [ebp - 4], 6
call sub.MFC42.DLL_CDaoRecordset::MoveFirst
lea edx, [ebp - 0x28]
lea ecx, [ebp - 0x198]
push edx
push str.lg_name
call sub.MFC42.DLL_CDaoRecordset::GetFieldValue
mov eax, dword [ebp - 0x20]
lea ecx, [ebp - 0x1d5]
push eax
push ecx
call esi
lea edx, [ebp - 0x28]
lea ecx, [ebp - 0x198]
push edx
push str.lg_tele
call sub.MFC42.DLL_CDaoRecordset::GetFieldValue
mov eax, dword [ebp - 0x20]
lea ecx, [ebp - 0x1ac]
push eax
push ecx
call esi
jmp 0x409a6f
lea ecx, [ebp - 0x198]
mov dword [ebp - 4], 5
call sub.MFC42.DLL_CDaoRecordset::Close
push ebx
lea eax, [ebp - 0x1e0]
push 0x45
lea ecx, [ebp - 0x44]
push eax
push ecx
call fcn.0040bd10
mov edx, dword [ebp - 0x14]
push ebx
push edx
push 0xffffffffffffffff
lea ecx, [ebp - 0x100]
call sub.MFC42.DLL_CDaoRecordset::Open
lea ecx, [ebp - 0x100]
mov byte [ebp - 4], 8
call sub.MFC42.DLL_CDaoRecordset::MoveFirst
lea ecx, [ebp - 0x100]
call sub.MFC42.DLL_CDaoRecordset::IsEOF
cmp eax, ebx
jne 0x409bf3
mov esi, 8
xor eax, eax
mov ecx, esi
lea edi, [ebp - 0x68]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [ebp - 0x28]
lea ecx, [ebp - 0x100]
push eax
push 0x416570
call sub.MFC42.DLL_CDaoRecordset::GetFieldValue
mov ecx, dword [ebp - 0x20]
mov edi, dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea edx, [ebp - 0x68]
push ecx
push edx
call edi
lea eax, [ebp - 0x28]
lea ecx, [ebp - 0x100]
push eax
push 0x416f3c
call sub.MFC42.DLL_CDaoRecordset::GetFieldValue
cmp word [ebp - 0x28], si
jne 0x409b21
mov ecx, dword [ebp - 0x20]
lea edx, [ebp - 0x5d]
push ecx
push edx
call edi
lea eax, [ebp - 0x28]
lea ecx, [ebp - 0x100]
push eax
push str.dhhm
call sub.MFC42.DLL_CDaoRecordset::GetFieldValue
cmp word [ebp - 0x28], si
jne 0x409b45
mov ecx, dword [ebp - 0x20]
lea edx, [ebp - 0x59]
push ecx
push edx
call edi
lea eax, [ebp - 0x28]
lea ecx, [ebp - 0x100]
push eax
push 0x416f30
call sub.MFC42.DLL_CDaoRecordset::GetFieldValue
cmp word [ebp - 0x28], si
jne 0x409b69
mov ecx, dword [ebp - 0x20]
lea edx, [ebp - 0x48]
push ecx
push edx
call edi
push ebx
lea eax, [ebp - 0x68]
push 0x23
lea ecx, [ebp - 0x44]
push eax
push ecx
call fcn.0040bd10
cmp eax, ebx
jge 0x409b87
lea ecx, [ebp - 0x44]
call fcn.0040bbe0
jmp 0x409bf3
lea ecx, [ebp - 0x100]
call sub.MFC42.DLL_CDaoRecordset::MoveNext
jmp 0x409ab5
lea ecx, [ebp - 0x100]
mov dword [ebp - 4], 5
call sub.MFC42.DLL_CDaoRecordset::Close
mov eax, dword [ebp - 0x3c]
cmp eax, 0x45
jae 0x409c73
lea ecx, [ebp - 0x198]
mov byte [ebp - 4], 4
call sub.MFC42.DLL_CDaoRecordset::CDaoRecordset
lea ecx, [ebp - 0x100]
mov byte [ebp - 4], 3
call sub.MFC42.DLL_CDaoRecordset::CDaoRecordset
lea eax, [ebp - 0x28]
push eax
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 1
call fcn.0040f504
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], bl
call fcn.0040f504
lea ecx, [ebp - 0x44]
mov dword [ebp - 4], 0xffffffff
call fcn.0040bbd0
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [ebp - 0x40]
mov edi, dword [ebp - 0x2c]
push eax
push ecx
mov ecx, dword [edi + 0x4b8]
push 0x59
push 0x1389
push 0x41667c
call fcn.0040e070
test eax, eax
je 0x409d7a
mov ecx, dword [edi + 0x4b8]
lea edx, [ebp + 8]
push 0x2bf20
push edx
push 0x138a
push 0x41667c
mov dword [ebp + 8], ebx
call fcn.0040dfd0
cmp eax, 0x16
jne 0x409d56
mov eax, dword [ebp + 8]
cmp eax, ebx
je 0x409d56
mov ecx, dword [eax + 0x12]
mov byte [ebp - 4], 4
cmp ecx, ebx
lea ecx, [ebp - 0x198]
jne 0x409d3c
call sub.MFC42.DLL_CDaoRecordset::CDaoRecordset
lea ecx, [ebp - 0x100]
mov byte [ebp - 4], 3
call sub.MFC42.DLL_CDaoRecordset::CDaoRecordset
lea eax, [ebp - 0x28]
push eax
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 1
call fcn.0040f504
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], bl
call fcn.0040f504
lea ecx, [ebp - 0x44]
mov dword [ebp - 4], 0xffffffff
call fcn.0040bbd0
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
call sub.MFC42.DLL_CDaoRecordset::CDaoRecordset
lea ecx, [ebp - 0x100]
mov byte [ebp - 4], 3
call sub.MFC42.DLL_CDaoRecordset::CDaoRecordset
lea ecx, [ebp - 0x28]
push ecx
jmp 0x409d9c
lea ecx, [ebp - 0x198]
mov byte [ebp - 4], 4
call sub.MFC42.DLL_CDaoRecordset::CDaoRecordset
lea ecx, [ebp - 0x100]
mov byte [ebp - 4], 3
call sub.MFC42.DLL_CDaoRecordset::CDaoRecordset
lea edx, [ebp - 0x28]
push edx
jmp 0x409d9c
lea ecx, [ebp - 0x198]
mov byte [ebp - 4], 4
call sub.MFC42.DLL_CDaoRecordset::CDaoRecordset
lea ecx, [ebp - 0x100]
mov byte [ebp - 4], 3
call sub.MFC42.DLL_CDaoRecordset::CDaoRecordset
lea eax, [ebp - 0x28]
push eax
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 1
call fcn.0040f504
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], bl
call fcn.0040f504
lea ecx, [ebp - 0x44]
mov dword [ebp - 4], 0xffffffff
call fcn.0040bbd0
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
xor eax, eax
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret 4