V
Size: a a a
V
ВС
V
ВС
events
(timeevent
datetime NOT NULL DEFAULT current_timestamp(),adlogon
varchar(250) NOT NULL DEFAULT 'Неизвестный',adpc
varchar(250) NOT NULL DEFAULT 'Неизвестно',event
enum('logon','logoff') NOT NULL,timeevent
),state
(event
),adlogon
(adlogon
)ВС
IZ
V
ВС
IZ
ВС
ВС
BS
ВС
timeevent
),NOW()) FROM events
WHERE adlogon=a.adlogon
AND adpc=a.adpc
AND timelogonstart < timeevent AND event
='logoff' LIMIT 1) AS timelogonend,timeevent
),NOW()) FROM events
WHERE adlogon=a.adlogon
AND adpc=a.adpc
AND timelogonstart < timeevent AND event
='logoff' LIMIT 1)) - TO_SECONDS(timeevent))) AS timeworkevents
AS aevent
= 'logon' AND (timeevent BETWEEN '2020-10-28 00:00:00' AND '2020-10-28 23:59:00')adlogon
,a.adpc
adlogon
DESCtimeevent
),NOW()) FROM events
WHERE adlogon=b.adlogon
AND adpc=b.adpc
AND (timelogoffstart < timeevent) AND event
='logon' LIMIT 1) AS timelogoffend,timeevent
),NOW()) FROM events
WHERE adlogon=b.adlogon
AND adpc=b.adpc
AND (TO_SECONDS(timelogoffstart) < TO_SECONDS(timeevent)) AND event
='logon' LIMIT 1)) - TO_SECONDS(timeevent))) AS timenotworkevents
AS bevent
= 'logoff' AND (timeevent BETWEEN '2020-10-28 00:00:00' AND '2020-10-28 23:59:00')adlogon
,b.adpc
tablea
.adlogon
= tableb
.adlogon
) AND (tablea
.adpc
= tableb
.adpc
)DE
events
(timeevent
datetime NOT NULL DEFAULT current_timestamp(),adlogon
varchar(250) NOT NULL DEFAULT 'Неизвестный',adpc
varchar(250) NOT NULL DEFAULT 'Неизвестно',event
enum('logon','logoff') NOT NULL,timeevent
),state
(event
),adlogon
(adlogon
)DE
DE
timeevent
),NOW()) FROM events
WHERE adlogon=a.adlogon
AND adpc=a.adpc
AND timelogonstart < timeevent AND event
='logoff' LIMIT 1) AS timelogonend,timeevent
),NOW()) FROM events
WHERE adlogon=a.adlogon
AND adpc=a.adpc
AND timelogonstart < timeevent AND event
='logoff' LIMIT 1)) - TO_SECONDS(timeevent))) AS timeworkevents
AS aevent
= 'logon' AND (timeevent BETWEEN '2020-10-28 00:00:00' AND '2020-10-28 23:59:00')adlogon
,a.adpc
adlogon
DESCtimeevent
),NOW()) FROM events
WHERE adlogon=b.adlogon
AND adpc=b.adpc
AND (timelogoffstart < timeevent) AND event
='logon' LIMIT 1) AS timelogoffend,timeevent
),NOW()) FROM events
WHERE adlogon=b.adlogon
AND adpc=b.adpc
AND (TO_SECONDS(timelogoffstart) < TO_SECONDS(timeevent)) AND event
='logon' LIMIT 1)) - TO_SECONDS(timeevent))) AS timenotworkevents
AS bevent
= 'logoff' AND (timeevent BETWEEN '2020-10-28 00:00:00' AND '2020-10-28 23:59:00')adlogon
,b.adpc
tablea
.adlogon
= tableb
.adlogon
) AND (tablea
.adpc
= tableb
.adpc
)DE
timeevent
),NOW()) FROM events
WHERE adlogon=a.adlogon
AND adpc=a.adpc
AND timelogonstart < timeevent AND event
='logoff' LIMIT 1) AS timelogonend,timeevent
),NOW()) FROM events
WHERE adlogon=a.adlogon
AND adpc=a.adpc
AND timelogonstart < timeevent AND event
='logoff' LIMIT 1)) - TO_SECONDS(timeevent))) AS timeworkevents
AS aevent
= 'logon' AND (timeevent BETWEEN '2020-10-28 00:00:00' AND '2020-10-28 23:59:00')adlogon
,a.adpc
adlogon
DESCtimeevent
),NOW()) FROM events
WHERE adlogon=b.adlogon
AND adpc=b.adpc
AND (timelogoffstart < timeevent) AND event
='logon' LIMIT 1) AS timelogoffend,timeevent
),NOW()) FROM events
WHERE adlogon=b.adlogon
AND adpc=b.adpc
AND (TO_SECONDS(timelogoffstart) < TO_SECONDS(timeevent)) AND event
='logon' LIMIT 1)) - TO_SECONDS(timeevent))) AS timenotworkevents
AS bevent
= 'logoff' AND (timeevent BETWEEN '2020-10-28 00:00:00' AND '2020-10-28 23:59:00')adlogon
,b.adpc
tablea
.adlogon
= tableb
.adlogon
) AND (tablea
.adpc
= tableb
.adpc
)ВС
ВС