LoTW import didn't import many stations - fixed

This commit is contained in:
Petr Hlozek 2014-01-03 20:33:13 +01:00
parent 2292072831
commit 605c974312

View File

@ -940,30 +940,33 @@ begin
t2 := t_lotw+5/1440;
if dmData.DebugLevel >=1 then Writeln(call,'|',TimeToStr(t_lotw),' | ',TimeToStr(t1),'|',TimeToStr(t2));
if (t_lotw >=t1) and (t_lotw<=t2) and (dmData.Q.Fields[1].AsString <> 'L') then
if (t_lotw >=t1) and (t_lotw<=t2) then
begin
if LoTWShowNew and (dmData.Q.Fields[1].AsString <> 'L') then //this qso is already confirmed
LoTWQSOList.Add(qsodate+ ' ' + call + ' ' + band + ' ' + mode);
dmData.Q1.Close;
dmData.Q1.SQL.Clear;
dmData.Q1.SQL.Add('update cqrlog_main set lotw_qslr = ' + QuotedStr('L'));
dmData.Q1.SQL.Add(',lotw_qslrdate = ' + QuotedStr(qslrdate));
if cqz<>'' then
dmData.Q1.SQL.Add(',waz = ' + QuotedStr(cqz));
if ituz<>'' then
dmData.Q1.SQL.Add(',itu = ' + QuotedStr(ituz));
if iota<>'' then
dmData.Q1.SQL.Add(',iota = ' + QuotedStr(iota));
if (grid <> '') and (dmData.Q.Fields[5].AsString='') then
dmData.Q1.SQL.Add(',loc = ' + QuotedStr(grid));
if (state<>'') and (dmData.Q.Fields[6].AsString='') then
dmData.Q1.SQL.Add(',state = ' + QuotedStr(state));
if (county<>'') and (dmData.Q.Fields[7].AsString='') then
dmData.Q1.SQL.Add(',county = ' + QuotedStr(county));
dmData.Q1.SQL.Add(' where id_cqrlog_main = ' + dmData.Q.Fields[8].AsString);
inc(qsln);
if dmData.DebugLevel>=1 then Writeln(dmData.Q1.SQL.Text+ ' qsl number:'+ IntToStr(qsln));
dmData.Q1.ExecSQL;
if (dmData.Q.Fields[1].AsString <> 'L') then
begin
if LoTWShowNew then //this qso is already confirmed
LoTWQSOList.Add(qsodate+ ' ' + call + ' ' + band + ' ' + mode);
dmData.Q1.Close;
dmData.Q1.SQL.Clear;
dmData.Q1.SQL.Add('update cqrlog_main set lotw_qslr = ' + QuotedStr('L'));
dmData.Q1.SQL.Add(',lotw_qslrdate = ' + QuotedStr(qslrdate));
if cqz<>'' then
dmData.Q1.SQL.Add(',waz = ' + QuotedStr(cqz));
if ituz<>'' then
dmData.Q1.SQL.Add(',itu = ' + QuotedStr(ituz));
if iota<>'' then
dmData.Q1.SQL.Add(',iota = ' + QuotedStr(iota));
if (grid <> '') and (dmData.Q.Fields[5].AsString='') then
dmData.Q1.SQL.Add(',loc = ' + QuotedStr(grid));
if (state<>'') and (dmData.Q.Fields[6].AsString='') then
dmData.Q1.SQL.Add(',state = ' + QuotedStr(state));
if (county<>'') and (dmData.Q.Fields[7].AsString='') then
dmData.Q1.SQL.Add(',county = ' + QuotedStr(county));
dmData.Q1.SQL.Add(' where id_cqrlog_main = ' + dmData.Q.Fields[8].AsString);
inc(qsln);
if dmData.DebugLevel>=1 then Writeln(dmData.Q1.SQL.Text+ ' qsl number:'+ IntToStr(qsln));
dmData.Q1.ExecSQL
end;
qso_in_log := True;
Break
end;