Commit 3b105274 authored by Jucelino Fonseca's avatar Jucelino Fonseca

Mapeamento/Ajustes

parent 1ad2e8ca
...@@ -831,21 +831,35 @@ procedure TExplorerV2.LoadAliasCompletion(piLinhas: string); ...@@ -831,21 +831,35 @@ procedure TExplorerV2.LoadAliasCompletion(piLinhas: string);
var ls_texto, var ls_texto,
ls_espaco : string; ls_espaco : string;
li_Pos : integer; li_Pos : integer;
ls_Alias : string;
ls_classe : string;
begin begin
ls_espaco := ' '; ls_espaco := ' ';
li_Pos := Pos(__FROM,uppercase(piLinhas));
if li_Pos > 0 then
begin
ls_texto :=trim(Copy(result,li_Pos + Length(__FROM),Length(piLinhas)));
end;
li_Pos := Pos(ls_espaco,trim(ls_texto));
if li_Pos > 0 then
begin
ls_classe := trim(Copy(ls_texto,0,li_Pos -1);
ls_texto := trim(Copy(ls_texto,li_Pos + 1,Length(ls_texto)));
li_Pos := Pos(ls_espaco,trim(ls_texto));
if li_Pos > 0 then
begin
ls_Alias := trim(Copy(ls_texto,0,li_Pos -1);
if UpperCase(ls_Alias) = 'AS' then
begin
ls_Alias := trim(Copy(ls_texto,li_Pos + 1 +li_Pos -1);
end
else
begin
li_Pos := Pos(__FROM,uppercase(piLinhas)); end;
if li_Pos > 0 then li_Pos := Pos(ls_espaco,ls_texto);
begin end;
ls_texto :=trim(Copy(result,li_Pos + Length(__FROM),Length(piLinhas))); end;
li_Pos := Pos(ls_espaco,trim(ls_texto));
while li_Pos > 0 do
begin
result :=trim(Copy(ls_texto,li_Pos + 1,Length(ls_texto)));
li_Pos := Pos(ls_espaco,result);
end;
end;
end; end;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment