1 prompt "Запит 3"
on sele bar 1 of xx1 do zapros1
on sele bar 2 of xx1 do zapros2
on sele bar 3 of xx1 do zapros3
define popup xx2 from 4,12 to 12,20
define bar 1 of xx2 prompt "абонент"
define bar 2 of xx2 prompt "плата"
define bar 3 of xx2 prompt "розмова"
define bar 4 of xx2 prompt "зона"
on sele popup xx2 do basa with bar ()
activ menu ats
deactiv menu ats
procedure basa
parameters k
close database
do case
case k = 1
use abon
browse
use
case k = 2
use mts
browse
use
case k = 3
use plata ​​p>
browse
use
case k = 4
use razg
browse
use
case k = 5
use zona
browse
use
endcase
7. Лістинг ПРОГРАМ. br/>
zapros1.prg
close database
use abon
use plata in 2
index on n_t to abon
sele 2
index on n_t to plata ​​p>
sele 1
set rela to n_t into 2
set filter to b.dolg> 100000
brow fields a.fio, b.dolg
set rela to
set filter to
zapros2.prg
clear p> set safe off
close database
set talk off
sele 1
use razg
index on n_z to k1
sele 2
use zona
index on n_z to k2
sele 1
set rela to n_z into 2
set skip to 2
c = date ()
@ 2,10 say "Введіть дату" get c
read
v = 0
@ 4,10 say "Введіть номер зони" get v
read
set filter to a.data_razg = c.and. b.n_z = v
browse fields a.data_razg, b.n_z, a.t, b.tar
X1 = a.T
X2 = b.Tar
h = a.T * b.tar
? h, a.n_t
set filter to
close database
zapros3.prg
clear p> set safe off
close database
set talk off
sele 1
use razg
index on n_z to k1
sele 2
use zona
index on n_z to k2
sele 1
set rela to n_z into 2
set skip to 2
c = date ()
@ 2,10 say "Введіть дату" get c
read
v = 0
@ 4,10 say "Введіть номер зони" get v
read
set filter to a.data_razg = c.and. b.n_z = v
browse fields a.data_razg, b.n_z, a.t, b.tar
X1 = a.T
X2 = b.Tar
h = a.T * b.tar
? h, a.n_t
set filter to
close database