Function at 0x101301b7
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x7c
mov edx, dword [esp + 0x80]
and dword [esp + 0x14], 0
push ebx
push ebp
mov ebp, dword [esp + 0x8c]
mov eax, dword [edx]
push esi
mov esi, dword [esp + 0x94]
push edi
push 7
pop ecx
lea edi, [esp + 0x38]
mov dword [esp + 0x18], eax
mov eax, dword [ebp + 0x34]
rep movsd dword es:[edi], dword [esi]
mov edi, eax
mov dword [esp + 0x20], ebp
mov ecx, dword [edi + 0x30]
test ecx, ecx
jne 0x10130860
cmp dword [edi + 0x3c], ecx
jne 0x10130860
mov esi, edx
push esi
call fcn.1014a41d
cmp byte [esp + 0x3c], 0xc
mov ebx, eax
pop ecx
mov dword [esp + 0x10], ebx
jne 0x10130233
mov ecx, dword [ebp + 0x1c]
push dword [ecx]
push dword [esp + 0x40]
push 0x64
push ebx
call fcn.101596d3
add esp, 0x10
mov byte [esp + 0x38], 0xe
mov eax, dword [ebp + 4]
test eax, 0x400
je 0x1013025d
lea eax, [esp + 0x38]
push eax
push ebp
push esi
call fcn.10131178
mov ebx, eax
add esp, 0xc
test ebx, ebx
jns 0x1013088c
mov eax, dword [ebp + 4]
mov ebx, dword [esp + 0x10]
mov ecx, 0x2000
test ecx, eax
je 0x10130292
mov eax, ebp
test dword [eax + 4], ecx
je 0x10130274
mov eax, dword [eax + 0x34]
test eax, eax
jne 0x10130268
test eax, eax
je 0x10130292
lea eax, [esp + 0x38]
push eax
push ebp
push esi
call fcn.1012ce2a
add esp, 0xc
xor ebx, ebx
mov dword [esp + 0x14], ebx
jmp 0x1013076c
cmp dword [ebp + 0x30], 0
je 0x101302af
mov ecx, dword [esp + 0x98]
push ecx
push ebp
push esi
call fcn.1013090a
add esp, 0xc
jmp 0x101308b2
cmp dword [edi + 0x34], 0
jne 0x101302d2
push str.COMPOUND_QUERY
push 1
push esi
call fcn.1015fa1f
push str.LEFT_MOST_SUBQUERY
push 1
push esi
call fcn.1015fa1f
add esp, 0x18
movzx eax, byte [ebp]
sub eax, 0x84
je 0x101305cb
sub eax, 1
je 0x101304b3
sub eax, 1
je 0x101305cb
mov ecx, dword [esi + 0x28]
push 0
push ecx
push 0x64
lea eax, [ecx + 1]
mov dword [esp + 0x28], ecx
mov dword [esp + 0x34], eax
inc eax
push ebx
mov dword [esi + 0x28], eax
call fcn.101596d3
mov dword [ebp + 0x14], eax
add esp, 0x10
mov ecx, dword [ebp + 0x38]
mov eax, ebp
jmp 0x10130322
mov eax, ecx
mov ecx, dword [eax + 0x38]
test ecx, ecx
jne 0x1013031d
or dword [eax + 4], 0x20
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x58], eax
xor eax, eax
mov dword [esp + 0x5c], eax
mov dword [esp + 0x68], eax
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], eax
lea eax, [esp + 0x54]
push eax
push edi
push esi
mov byte [esp + 0x60], 1
call fcn.10153d2c
mov ebx, eax
add esp, 0xc
test ebx, ebx
jne 0x1013088c
mov ebx, dword [esp + 0x28]
push eax
push ebx
push 0x64
push dword [esp + 0x1c]
call fcn.101596d3
mov dword [ebp + 0x18], eax
mov eax, dword [ebp + 0x3c]
and dword [ebp + 0x34], 0
and dword [ebp + 0x3c], 0
mov dword [esp + 0x3c], eax
movzx eax, byte [ebp]
push eax
mov dword [esp + 0x6c], ebx
call fcn.10139bf9
push eax
push str._s_USING_TEMP_B_TREE
push 1
push esi
call fcn.1015fa1f
lea eax, [esp + 0x78]
push eax
push ebp
push esi
call fcn.10153d2c
mov ebx, eax
add esp, 0x30
mov eax, dword [ebp + 0x34]
mov dword [esp + 0x24], eax
mov dword [ebp + 0x34], edi
movzx eax, word [edi + 2]
mov dword [esp + 0x14], ebx
cmp word [ebp + 2], ax
jle 0x101303ce
mov word [ebp + 2], ax
cmp dword [ebp + 0x3c], 0
je 0x101303e2
push dword [ebp + 0x3c]
push dword [esp + 0x1c]
call fcn.10145850
pop ecx
pop ecx
mov eax, dword [esp + 0x2c]
mov dword [ebp + 0x3c], eax
test ebx, ebx
jne 0x1013075f
mov ebp, dword [esi + 0x38]
dec ebp
push ebp
push dword [esp + 0x24]
lea ebx, [ebp - 1]
push esi
mov dword [esi + 0x38], ebx
call fcn.10125fb7
mov edi, dword [esp + 0x1c]
push ebp
push dword [esp + 0x2c]
push 0x25
push edi
call fcn.101596d3
push esi
call fcn.10149be5
mov esi, eax
push esi
push dword [esp + 0x40]
push 0x7f
push edi
call fcn.101596d3
push 0
push esi
push ebx
push dword [esp + 0x64]
mov edi, eax
push 0x1d
push dword [esp + 0x54]
call fcn.1014ecdb
add esp, 0x48
push esi
mov esi, dword [esp + 0x94]
push esi
call fcn.10152995
push ebp
push ebx
lea eax, [esp + 0x48]
push eax
push 0
push 0
push dword [esp + 0x38]
push dword [esp + 0x40]
push esi
call fcn.10139431
push ebx
push dword [esp + 0x3c]
call fcn.10161d60
mov ebx, dword [esp + 0x4c]
push edi
mov edi, dword [esp + 0x44]
push ebx
push 5
push edi
call fcn.101596d3
add esp, 0x40
push ebp
push edi
call fcn.10161d60
push 0
lea eax, [ebx + 1]
push eax
push 0x74
push edi
call fcn.101596d3
push 0
push ebx
push 0x74
push edi
call fcn.101596d3
mov ebp, dword [esp + 0x48]
jmp 0x10130758
xor eax, eax
mov dword [esp + 0x28], eax
mov eax, dword [ebp + 8]
mov dword [edi + 8], eax
mov eax, dword [ebp + 0xc]
mov dword [edi + 0xc], eax
mov eax, dword [ebp + 0x3c]
mov dword [edi + 0x3c], eax
lea eax, [esp + 0x38]
push eax
push edi
push esi
call fcn.10153d2c
and dword [ebp + 0x3c], 0
mov ebx, eax
add esp, 0xc
test ebx, ebx
jne 0x1013088c
and dword [ebp + 0x34], eax
mov ecx, dword [edi + 8]
mov dword [ebp + 8], ecx
mov eax, dword [edi + 0xc]
mov dword [ebp + 0xc], eax
test ecx, ecx
je 0x1013052a
mov ebx, dword [esp + 0x10]
push ecx
push 0x14
push ebx
call fcn.101596ba
mov ecx, dword [ebp + 0xc]
add esp, 0xc
mov dword [esp + 0x28], eax
test ecx, ecx
je 0x1013052a
push ecx
inc ecx
push ecx
push dword [ebp + 8]
push 0x99
push ebx
call fcn.1014ecdb
add esp, 0x14
push str.UNION_ALL
push 1
push esi
call fcn.1015fa1f
lea eax, [esp + 0x44]
push eax
push ebp
push esi
call fcn.10153d2c
mov ebx, eax
mov eax, dword [ebp + 0x34]
mov dword [esp + 0x3c], eax
mov dword [ebp + 0x34], edi
movzx eax, word [edi + 2]
push eax
movzx eax, word [ebp + 2]
push eax
mov dword [esp + 0x34], ebx
call fcn.1014cdff
movzx eax, ax
add esp, 0x20
mov dword [esp + 0x1c], eax
mov word [ebp + 2], ax
mov eax, dword [edi + 0x3c]
test eax, eax
je 0x101305a7
lea ecx, [esp + 0x2c]
push ecx
push dword [eax + 0xc]
call fcn.1014ecdb
pop ecx
pop ecx
test eax, eax
je 0x101305a7
mov eax, dword [esp + 0x2c]
test eax, eax
jle 0x101305a7
cdq
push edx
push eax
call fcn.1014cd7a
pop ecx
pop ecx
cmp word [esp + 0x1c], ax
jle 0x101305a7
mov word [ebp + 2], ax
mov eax, dword [esp + 0x28]
test eax, eax
je 0x1013075f
mov edi, dword [esp + 0x10]
push eax
push edi
call fcn.1015fcbe
pop ecx
pop ecx
mov ecx, dword [edi + 0x6c]
mov dword [eax + 8], ecx
jmp 0x1013075f
cmp byte [esp + 0x38], 1
jne 0x101305dc
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x1c], eax
jmp 0x10130612
mov ecx, dword [esi + 0x28]
push 0
push ecx
push 0x64
lea eax, [ecx + 1]
mov dword [esp + 0x28], ecx
push ebx
mov dword [esi + 0x28], eax
call fcn.101596d3
mov dword [ebp + 0x14], eax
add esp, 0x10
mov ecx, dword [ebp + 0x38]
mov eax, ebp
jmp 0x10130606
mov eax, ecx
mov ecx, dword [eax + 0x38]
test ecx, ecx
jne 0x10130601
or dword [eax + 4], 0x20
mov eax, dword [esp + 0x1c]
push eax
lea eax, [esp + 0x74]
push 1
push eax
call fcn.101553fc
lea eax, [esp + 0x7c]
push eax
push edi
push esi
call fcn.10153d2c
mov ebx, eax
add esp, 0x18
test ebx, ebx
jne 0x1013088c
and dword [ebp + 0x34], eax
mov eax, dword [ebp + 0x3c]
and dword [ebp + 0x3c], ebx
cmp byte [ebp], 0x86
mov dword [esp + 0x2c], eax
sete al
inc al
mov byte [esp + 0x70], al
movzx eax, byte [ebp]
push eax
call fcn.10139bf9
push eax
push str._s_USING_TEMP_B_TREE
push 1
push esi
call fcn.1015fa1f
lea eax, [esp + 0x84]
push eax
push ebp
push esi
call fcn.10153d2c
and dword [ebp + 0x30], 0
mov ebx, eax
mov eax, dword [ebp + 0x34]
add esp, 0x20
cmp byte [ebp], 0x84
mov dword [esp + 0x14], ebx
mov dword [esp + 0x24], eax
mov dword [ebp + 0x34], edi
jne 0x101306ab
movzx eax, word [edi + 2]
push eax
movzx eax, word [ebp + 2]
push eax
call fcn.1014cdff
pop ecx
pop ecx
mov word [ebp + 2], ax
cmp dword [ebp + 0x3c], 0
mov edi, dword [esp + 0x18]
je 0x101306c0
push dword [ebp + 0x3c]
push edi
call fcn.10145850
pop ecx
pop ecx
and dword [ebp + 8], 0
and dword [ebp + 0xc], 0
cmp byte [esp + 0x38], 1
mov eax, dword [esp + 0x2c]
mov dword [ebp + 0x3c], eax
je 0x1013075f
cmp byte [edi + 0x51], 0
jne 0x1013075f
mov ebx, dword [esi + 0x38]
dec ebx
push ebx
push ebp
push esi
lea edi, [ebx - 1]
mov dword [esi + 0x38], edi
call fcn.10125fb7
mov esi, dword [esp + 0x1c]
push ebx
push dword [esp + 0x2c]
push 0x25
push esi
call fcn.101596d3
mov edx, dword [esp + 0xac]
lea eax, [esp + 0x54]
mov esi, dword [esi + 0x6c]
push ebx
push edi
push eax
push 0
push 0
push dword [esp + 0x4c]
push ebp
push edx
call fcn.10139431
push edi
mov edi, dword [esp + 0x50]
push edi
call fcn.10161d60
add esp, 0x44
push esi
mov esi, dword [esp + 0x20]
push esi
push 5
push edi
call fcn.101596d3
push ebx
push edi
call fcn.10161d60
push 0
push esi
push 0x74
push edi
call fcn.101596d3
mov esi, dword [esp + 0xb8]
mov ebx, dword [esp + 0x3c]
add esp, 0x28
cmp dword [ebp + 0x38], 0
jne 0x1013076c
push esi
call fcn.1015fa6e
pop ecx
cmp dword [esi + 0x24], 0
jne 0x1013088c
test byte [ebp + 4], 0x20
je 0x1013088c
mov eax, dword [ebp + 0x1c]
push 1
mov eax, dword [eax]
push eax
push dword [esp + 0x20]
mov dword [esp + 0x28], eax
call fcn.1014c3a0
mov edi, eax
add esp, 0xc
mov dword [esp + 0x34], edi
test edi, edi
jne 0x101307aa
push 7
pop ebx
jmp 0x1013088c
and dword [esp + 0x30], 0
lea eax, [edi + 0x14]
cmp dword [esp + 0x1c], 0
mov dword [esp + 0x28], eax
jle 0x101307ef
mov ebx, dword [esp + 0x30]
mov edi, eax
push ebx
push ebp
push esi
call fcn.101308ba
add esp, 0xc
mov dword [edi], eax
test eax, eax
jne 0x101307dd
mov eax, dword [esp + 0x18]
mov eax, dword [eax + 8]
mov dword [edi], eax
inc ebx
add edi, 4
cmp ebx, dword [esp + 0x1c]
jl 0x101307c3
mov ebx, dword [esp + 0x14]
mov edi, dword [esp + 0x34]
and dword [esp + 0x28], 0
lea eax, [ebp + 0x14]
mov esi, dword [esp + 0x10]
mov ebp, dword [esp + 0x1c]
mov dword [esp + 0x14], eax
mov eax, dword [eax]
mov dword [esp + 0x34], eax
test eax, eax
js 0x10130848
push eax
push esi
lfence
call fcn.1015fcbe
push 0xfffffffffffffff7
push edi
push dword [esp + 0x44]
mov dword [eax + 8], ebp
inc dword [edi]
push esi
call fcn.1014ecdb
mov eax, dword [esp + 0x2c]
add esp, 0x18
mov ecx, dword [esp + 0x28]
or dword [eax], 0xffffffff
inc ecx
add eax, 4
mov dword [esp + 0x28], ecx
mov dword [esp + 0x14], eax
cmp ecx, 2
jl 0x10130803
mov ebp, dword [esp + 0x20]
mov ebp, dword [ebp + 0x34]
mov dword [esp + 0x20], ebp
test ebp, ebp
jne 0x101307ef
push edi
call fcn.1014c558
pop ecx
jmp 0x1013088c
movzx eax, byte [ebp]
push eax
call fcn.10139bf9
push eax
test ecx, ecx
mov eax, str.ORDER_BY
mov esi, str.LIMIT
cmove eax, esi
push eax
push str._s_clause_should_come_after__s_not_before
push edx
call fcn.10143429
xor ebx, ebx
add esp, 0x14
inc ebx
mov ecx, dword [esp + 0x98]
mov eax, dword [esp + 0x44]
push dword [esp + 0x24]
push dword [esp + 0x1c]
mov dword [ecx + 0xc], eax
mov eax, dword [esp + 0x50]
mov dword [ecx + 0x10], eax
call fcn.101553e2
pop ecx
pop ecx
mov eax, ebx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x7c
ret