Function at 0x652605e0
Capabilities:
Reference sql statements

Disassembly:
sub esp, 0x10
push ebx
push ebp
mov ebp, dword [esp + 0x1c]
push edi
push 0
push 0
push 0x652e6f48
push 1
mov edi, ecx
push 2
push str.SI_FOREIGN_KEYS
lea eax, [esp + 0x38]
lea ecx, [esp + 0x28]
lea edx, [ebp + 0x10]
lea ebx, [edi + 8]
push ebx
mov dword [esp + 0x28], 0
mov dword [0x652e6f5c], eax
mov dword [0x652e6f88], ecx
mov dword [0x652e6fb4], edx
call sub.dblib8.dll_Ordinal_254
mov eax, dword [edi + 0x14]
test eax, eax
jge 0x65260644
mov ecx, dword [edi + 0x90]
test ecx, ecx
jne 0x65260642
mov dword [edi + 0x90], eax
test eax, eax
jne 0x652606e2
mov ecx, dword [esp + 0x10]
mov eax, dword [esp + 0x20]
push 0
push 2
push 0
push 0
push str.SELECT_primary_column_id__foreign_column_id_n_FROM_SYS.SYSFKCOL_n_WHERE_foreign_table_id__:nfkFTid_AND_foreign_key_id__:nfkid_n_ORDER_BY_foreign_column_id
mov dword [ebp + 4], ecx
mov ecx, dword [str.syncinfo]
push 0x652fa984
push ecx
mov dword [ebp], eax
push 0
lea edx, [esp + 0x44]
lea eax, [esp + 0x40]
push ebx
mov dword [0x652e709c], edx
mov dword [0x652e70c8], eax
call sub.dblib8.dll_Ordinal_260
mov eax, dword [edi + 0x14]
test eax, eax
jge 0x652606a3
mov ecx, dword [edi + 0x90]
test ecx, ecx
jne 0x652606a3
mov dword [edi + 0x90], eax
mov edx, dword [str.syncinfo]
push 1
push 0
push 0
push 0x652e7088
push 0x652fa984
push edx
push 0
push str.SI_FK_COL
push ebx
call sub.dblib8.dll_Ordinal_258
mov eax, dword [edi + 0x14]
test eax, eax
jge 0x652606e0
mov ecx, dword [edi + 0x90]
test ecx, ecx
jne 0x652606de
mov dword [edi + 0x90], eax
test eax, eax
je 0x652606ed
pop edi
pop ebp
xor eax, eax
pop ebx
add esp, 0x10
ret 8
push 0xc
call fcn.6527b505
add esp, 4
test eax, eax
je 0x65260706
push 2
mov ecx, eax
call fcn.6521c6c0
jmp 0x65260708
xor eax, eax
push 0xc
mov dword [ebp + 0xc], eax
call fcn.6527b505
add esp, 4
test eax, eax
je 0x65260724
push 2
mov ecx, eax
call fcn.6521c6c0
jmp 0x65260726
xor eax, eax
mov dword [ebp + 8], eax
push esi
lea ebx, [ebx]
push 0
push 0
push 0x652e70f0
push 1
push 2
push str.SI_FK_COL
lea eax, [esp + 0x30]
lea ecx, [esp + 0x34]
push ebx
mov dword [0x652e7104], eax
mov dword [0x652e7130], ecx
call sub.dblib8.dll_Ordinal_254
mov eax, dword [edi + 0x14]
test eax, eax
jge 0x65260772
mov ecx, dword [edi + 0x90]
test ecx, ecx
jne 0x65260772
mov dword [edi + 0x90], eax
cmp eax, 0x64
je 0x652607f4
mov esi, dword [ebp + 0xc]
mov eax, dword [esi + 4]
cmp dword [esi + 8], eax
jne 0x652607a0
add eax, eax
lea edx, [eax*4]
mov dword [esi + 4], eax
mov eax, dword [esi]
push edx
push eax
call fcn.65244240
add esp, 8
test eax, eax
mov dword [esi], eax
je 0x652607af
mov eax, dword [esp + 0x18]
mov ecx, dword [esi + 8]
mov edx, dword [esi]
mov dword [edx + ecx*4], eax
inc dword [esi + 8]
mov esi, dword [ebp + 8]
mov eax, dword [esi + 4]
cmp dword [esi + 8], eax
jne 0x652607d8
mov edx, dword [esi]
add eax, eax
lea ecx, [eax*4]
push ecx
push edx
mov dword [esi + 4], eax
call fcn.65244240
add esp, 8
test eax, eax
mov dword [esi], eax
je 0x652607e7
mov eax, dword [esi + 8]
mov edx, dword [esp + 0x1c]
mov ecx, dword [esi]
mov dword [ecx + eax*4], edx
inc dword [esi + 8]
mov eax, dword [edi + 0x14]
test eax, eax
je 0x65260730
jmp 0x652607fc
mov dword [esp + 0x10], 1
push str.SI_FK_COL
push ebx
call sub.dblib8.dll_Ordinal_237
mov eax, dword [edi + 0x14]
test eax, eax
jge 0x6526081e
mov ecx, dword [edi + 0x90]
test ecx, ecx
jne 0x6526081e
mov dword [edi + 0x90], eax
mov eax, dword [esp + 0x10]
test eax, eax
jne 0x6526086c
mov esi, dword [ebp + 0xc]
xor edi, edi
cmp esi, edi
je 0x65260847
mov eax, dword [esi]
cmp eax, edi
je 0x6526083e
push eax
call fcn.652440f0
add esp, 4
push esi
call fcn.6527b500
add esp, 4
mov esi, dword [ebp + 8]
cmp esi, edi
je 0x65260866
mov eax, dword [esi]
cmp eax, edi
je 0x6526085d
push eax
call fcn.652440f0
add esp, 4
push esi
call fcn.6527b500
add esp, 4
mov dword [ebp + 8], edi
mov dword [ebp + 0xc], edi
mov eax, dword [esp + 0x10]
pop esi
pop edi
pop ebp
pop ebx
add esp, 0x10
ret 8