# [18-Jan-2024 11:13:28] /techco/www/tNw2sPa4q/bg/ajax/users/login.html?_=1705569209674 167.99.142.201

set names utf8

UPDATE
                `users`
            SET
                `LastUpdate` = NOW(),
                `AccessKey` = 'x9T5Bio8wtd0iipHE7B2xioWQ6NRGqQw7X6WHvu3A5Ox1C04CKQzQhL8obr51074'
            WHERE
                `UserKey` LIKE 'w4vCvMOjwr7CjcKyw5rDi8OUw57DgsOCwq7DlMK3wpnCtMKu%' AND
                RIGHT(`UserKey`, 1) > 0
            LIMIT 1
# [18-Jan-2024 11:13:29] /techco/www/tNw2sPa4q/bg/ajax/users/login.html?_=1705569210729 167.99.142.201

set names utf8

SELECT
                `ID`,
                CRC32(`UserKey`) AS `User`,
                SUBSTRING(`UserKey`, -33, 32) AS `PassKey`,
                RIGHT(`UserKey`, 1) AS `Access`
            FROM
                `users`
            WHERE
                RIGHT(`UserKey`, 1) > 0 AND
                `LastUpdate` >= DATE_SUB(NOW(), INTERVAL 1 MINUTE) AND
                `AccessKey` = 'x9T5Bio8wtd0iipHE7B2xioWQ6NRGqQw7X6WHvu3A5Ox1C04CKQzQhL8obr51074'
            LIMIT 1

UPDATE
                `users`
            SET
                `LastUpdate` = NOW(),
                `AccessKey` = ''
            WHERE
                `ID` = 1
            LIMIT 1
# [18-Jan-2024 11:13:29] /techco/www/tNw2sPa4q/bg/pages/list.html 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `ID`,
                `Language`,
                `Module`,
                `Action`,
                `PostDate`,
                `LastUpdate`,
                IF(`MenuLabel` <> '', `MenuLabel`, `FooterLabel`) AS `Label`,
                `URLLabel`,
                `Visible`
            FROM
                `pages`
            WHERE
                `Language` = 'bg'
                
            ORDER BY  `ID` ASC

SELECT `URLLabel` FROM `pages` WHERE `Language` = 'bg' AND
	`ParentID` = 1 AND
	`Module` = 'contacts' ORDER BY `PostDate` ASC, `LastUpdate` DESC LIMIT 1

SELECT `URLLabel` FROM `pages` WHERE `Language` = 'bg' AND
	`ParentID` = 1 AND
	`Module` = 'contacts' ORDER BY `PostDate` ASC, `LastUpdate` DESC LIMIT 1
# [18-Jan-2024 11:13:32] /techco/www/tNw2sPa4q/bg/newsletter/list.html 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `ID`,
                `Language`,
                `PostDate`,
                `LastUpdate`,
                `Title`,
                `URLLabel`,
                `Visible`
            FROM
                `newsletter`
            WHERE
                `Language` = 'bg'
         ORDER BY `PostDate` DESC LIMIT 0, 30

SELECT COUNT(*) AS NumRows FROM (
            SELECT
                `ID`,
                `Language`,
                `PostDate`,
                `LastUpdate`,
                `Title`,
                `URLLabel`,
                `Visible`
            FROM
                `newsletter`
            WHERE
                `Language` = 'bg'
         ORDER BY `PostDate` DESC) AS CountTable
# [18-Jan-2024 11:13:35] /techco/www/tNw2sPa4q/bg/newsletter/subscribers.html 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `newsletter_subscribers`.`ID`,
                `newsletter_subscribers`.`Language`,
                `newsletter_subscribers`.`PostDate`,
                `newsletter_subscribers`.`Data`,
                `newsletter_subscribers`.`Confirmed`
            FROM
                `newsletter_subscribers`
                LEFT JOIN `newsletter_unsubscribed` ON `newsletter_subscribers`.`ID` = `newsletter_unsubscribed`.`ID`
            WHERE
                `newsletter_unsubscribed`.`ID` IS NULL AND
                `newsletter_subscribers`.`Language` = 'bg'
         ORDER BY `newsletter_subscribers`.`PostDate` DESC LIMIT 0, 30
# [18-Jan-2024 11:13:36] /techco/www/tNw2sPa4q/bg/import/newsletter.html 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1
# [18-Jan-2024 11:13:44] /techco/www/tNw2sPa4q/bg/ajax/import/upload.html 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1
# [18-Jan-2024 11:13:44] /techco/www/tNw2sPa4q/bg/ajax/import/table.html?_=1705569225813 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1
# [18-Jan-2024 12:11:36] /techco/www/tNw2sPa4q/ 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1
# [18-Jan-2024 12:11:36] /techco/www/tNw2sPa4q/bg/ajax/users/form/login.html?_=1705572697649 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1
# [18-Jan-2024 12:11:40] /techco/www/tNw2sPa4q/ 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1
# [18-Jan-2024 12:11:40] /techco/www/tNw2sPa4q/bg/ajax/users/form/login.html?_=1705572701631 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1
# [18-Jan-2024 12:12:34] /techco/www/tNw2sPa4q/ 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1
# [18-Jan-2024 12:12:34] /techco/www/tNw2sPa4q/bg/ajax/users/form/login.html?_=1705572755329 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1
# [18-Jan-2024 12:12:38] /techco/www/tNw2sPa4q/bg/ajax/users/login.html?_=1705572759577 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

UPDATE
                `users`
            SET
                `LastUpdate` = NOW(),
                `AccessKey` = '3CLhuYiSPf9cZPm4cNobmqEUHs0K5RR368kdWSolnH84FyBK71lHx1nDAGy4Qxu1'
            WHERE
                `UserKey` LIKE 'w4vCvMOjwr7CjcKyw5rDi8OUw57DgsOCwq7DlMK3wpnCtMKu%' AND
                RIGHT(`UserKey`, 1) > 0
            LIMIT 1
# [18-Jan-2024 12:12:39] /techco/www/tNw2sPa4q/bg/ajax/users/login.html?_=1705572760319 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `ID`,
                CRC32(`UserKey`) AS `User`,
                SUBSTRING(`UserKey`, -33, 32) AS `PassKey`,
                RIGHT(`UserKey`, 1) AS `Access`
            FROM
                `users`
            WHERE
                RIGHT(`UserKey`, 1) > 0 AND
                `LastUpdate` >= DATE_SUB(NOW(), INTERVAL 1 MINUTE) AND
                `AccessKey` = '3CLhuYiSPf9cZPm4cNobmqEUHs0K5RR368kdWSolnH84FyBK71lHx1nDAGy4Qxu1'
            LIMIT 1

UPDATE
                `users`
            SET
                `LastUpdate` = NOW(),
                `AccessKey` = ''
            WHERE
                `ID` = 1
            LIMIT 1
# [18-Jan-2024 12:12:39] /techco/www/tNw2sPa4q/bg/pages/list.html 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `ID`,
                `Language`,
                `Module`,
                `Action`,
                `PostDate`,
                `LastUpdate`,
                IF(`MenuLabel` <> '', `MenuLabel`, `FooterLabel`) AS `Label`,
                `URLLabel`,
                `Visible`
            FROM
                `pages`
            WHERE
                `Language` = 'bg'
                
            ORDER BY  `ID` ASC

SELECT `URLLabel` FROM `pages` WHERE `Language` = 'bg' AND
	`ParentID` = 1 AND
	`Module` = 'contacts' ORDER BY `PostDate` ASC, `LastUpdate` DESC LIMIT 1

SELECT `URLLabel` FROM `pages` WHERE `Language` = 'bg' AND
	`ParentID` = 1 AND
	`Module` = 'contacts' ORDER BY `PostDate` ASC, `LastUpdate` DESC LIMIT 1
# [18-Jan-2024 12:12:45] /techco/www/tNw2sPa4q/bg/newsletter/list.html 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `ID`,
                `Language`,
                `PostDate`,
                `LastUpdate`,
                `Title`,
                `URLLabel`,
                `Visible`
            FROM
                `newsletter`
            WHERE
                `Language` = 'bg'
         ORDER BY `PostDate` DESC LIMIT 0, 30

SELECT COUNT(*) AS NumRows FROM (
            SELECT
                `ID`,
                `Language`,
                `PostDate`,
                `LastUpdate`,
                `Title`,
                `URLLabel`,
                `Visible`
            FROM
                `newsletter`
            WHERE
                `Language` = 'bg'
         ORDER BY `PostDate` DESC) AS CountTable
# [18-Jan-2024 12:12:47] /techco/www/tNw2sPa4q/bg/newsletter/1.html 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `URLLabel`,
                `Title`,
                `Content`
            FROM
                `newsletter`
            WHERE
                `ID` = 1 AND
                `Language` = 'bg'
            LIMIT 1

SELECT
                `newsletter_send`.`ID` AS `SendID`,
                `newsletter_send`.`NewsletterID`,
                `newsletter_send`.`PostDate`,
                `newsletter_send`.`Subject`,
                COUNT(`newsletter_users`.`UserKey`) AS `Subscribers`,
                COUNT(CASE WHEN `newsletter_users`.`SendKey` = '' THEN 1 END) AS `Progress`,
                SUM(`newsletter_users`.`Sent`) AS `Sent`,
                SUM(`newsletter_users`.`Opened`) AS `Opened`,
                SUM(`newsletter_users`.`Clicked`) AS `Clicked`
            FROM
                `newsletter`
                INNER JOIN `newsletter_send` ON
                    `newsletter`.`ID` = `newsletter_send`.`NewsletterID` AND
                    `newsletter`.`Language` = `newsletter_send`.`Language`
                LEFT JOIN `newsletter_users` ON `newsletter_users`.`SendID` = `newsletter_send`.`ID`
            WHERE
                `newsletter_send`.`NewsletterID` = 1 AND
                `newsletter`.`Language` = 'bg'
            GROUP BY
                `newsletter_send`.`ID`
            ORDER BY `PostDate` DESC
# [18-Jan-2024 12:12:52] /techco/www/tNw2sPa4q/bg/ajax/newsletter/form/send/1.html?_=1705572773592 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `URLLabel`,
                `Title`,
                `Content`
            FROM
                `newsletter`
            WHERE
                `ID` = 1 AND
                `Language` = 'bg'
            LIMIT 1

SELECT DISTINCT `ClientGroup` FROM `newsletter_subscribers` ORDER BY `ClientGroup` ASC
# [18-Jan-2024 12:13:02] /techco/www/tNw2sPa4q/bg/ajax/newsletter/form/send/1.html?_=1705572783255 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `URLLabel`,
                `Title`,
                `Content`
            FROM
                `newsletter`
            WHERE
                `ID` = 1 AND
                `Language` = 'bg'
            LIMIT 1

SELECT DISTINCT `ClientGroup` FROM `newsletter_subscribers` ORDER BY `ClientGroup` ASC
# [18-Jan-2024 12:13:09] /techco/www/tNw2sPa4q/bg/ajax/newsletter/addsend/1.html?_=1705572790685 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `URLLabel`,
                `Title`,
                `Content`
            FROM
                `newsletter`
            WHERE
                `ID` = 1 AND
                `Language` = 'bg'
            LIMIT 1

SELECT * FROM `newsletter_send` LIMIT 1

SHOW COLUMNS FROM `newsletter_send`

INSERT INTO `newsletter_send` SET `Language` = 'bg', `NewsletterID` = '1', `PostDate` = '2024-01-18 12:13:09', `Subject` = 'test', `Content` = '<h1>test</h1><div>sdfasd fasd fasdfasdfasdf <a href="https://maxgraphic.bg">asdf</a></div><div><img src="/techco/www/uf/newsletter/4975425074/i_teslax1.jpg"></div>'

SELECT * FROM `newsletter_users` LIMIT 1

SHOW COLUMNS FROM `newsletter_users`

REPLACE INTO `newsletter_users` SET `SendID` = 10, `UserKey` = '53a7c0e5c48bc7fa6824548c1ddaf4f33d4c046d6aa89b45add085813b886a67', `Data` = 'BMuWFWaRNU3NwfzqiAfwGFwPH3fGLBO89OuDRm_doSZRbgllZ3X5DUakb0fU2OJmgtwhUX3x6S3JVvb073osRfzY17gsfjUKalv1e__AQFtP6LbSGYNKbxa8MP3ufYPf', `SendKey` = '17bb2cecd2a3d1e7bac8dc4822d47653'

DELETE
                `newsletter_users`
            FROM
                `newsletter_users`
                INNER JOIN `newsletter_unsubscribed` ON `newsletter_users`.`UserKey` = `newsletter_unsubscribed`.`ID`
            WHERE
                `newsletter_users`.`SendID` = 10
# [18-Jan-2024 12:13:22] /techco/www/tNw2sPa4q/bg/newsletter/1.html 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `URLLabel`,
                `Title`,
                `Content`
            FROM
                `newsletter`
            WHERE
                `ID` = 1 AND
                `Language` = 'bg'
            LIMIT 1

SELECT
                `newsletter_send`.`ID` AS `SendID`,
                `newsletter_send`.`NewsletterID`,
                `newsletter_send`.`PostDate`,
                `newsletter_send`.`Subject`,
                COUNT(`newsletter_users`.`UserKey`) AS `Subscribers`,
                COUNT(CASE WHEN `newsletter_users`.`SendKey` = '' THEN 1 END) AS `Progress`,
                SUM(`newsletter_users`.`Sent`) AS `Sent`,
                SUM(`newsletter_users`.`Opened`) AS `Opened`,
                SUM(`newsletter_users`.`Clicked`) AS `Clicked`
            FROM
                `newsletter`
                INNER JOIN `newsletter_send` ON
                    `newsletter`.`ID` = `newsletter_send`.`NewsletterID` AND
                    `newsletter`.`Language` = `newsletter_send`.`Language`
                LEFT JOIN `newsletter_users` ON `newsletter_users`.`SendID` = `newsletter_send`.`ID`
            WHERE
                `newsletter_send`.`NewsletterID` = 1 AND
                `newsletter`.`Language` = 'bg'
            GROUP BY
                `newsletter_send`.`ID`
            ORDER BY `PostDate` DESC
# [18-Jan-2024 12:13:27] /techco/www/tNw2sPa4q/bg/ajax/newsletter/form/send/1.html?_=1705572808834 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `URLLabel`,
                `Title`,
                `Content`
            FROM
                `newsletter`
            WHERE
                `ID` = 1 AND
                `Language` = 'bg'
            LIMIT 1

SELECT DISTINCT `ClientGroup` FROM `newsletter_subscribers` ORDER BY `ClientGroup` ASC
# [18-Jan-2024 12:13:46] /techco/www/tNw2sPa4q/bg/ajax/newsletter/addsend/1.html?_=1705572827199 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `URLLabel`,
                `Title`,
                `Content`
            FROM
                `newsletter`
            WHERE
                `ID` = 1 AND
                `Language` = 'bg'
            LIMIT 1

SELECT * FROM `newsletter_send` LIMIT 1

SHOW COLUMNS FROM `newsletter_send`

INSERT INTO `newsletter_send` SET `Language` = 'bg', `NewsletterID` = '1', `PostDate` = '2024-01-18 12:13:46', `Subject` = 'test', `Content` = '<h1>test</h1><div>sdfasd fasd fasdfasdfasdf <a href="https://maxgraphic.bg">asdf</a></div><div><img src="/techco/www/uf/newsletter/4975425074/i_teslax1.jpg"></div>'

SELECT * FROM `newsletter_users` LIMIT 1

SHOW COLUMNS FROM `newsletter_users`

REPLACE INTO `newsletter_users` SET `SendID` = 11, `UserKey` = '53a7c0e5c48bc7fa6824548c1ddaf4f33d4c046d6aa89b45add085813b886a67', `Data` = 'nxlKlAC7ms39TAqqR-rTUDZNVXqyUxD2nut7qfTq3Z8VSYAdaR_wonv6aR_pDpXgeoiA2szNUwNuJ6nB6kxbA-iM57kTN-3SB9Gyryw9XIRc3iXENatUm3l9nVS_oqsW', `SendKey` = '70eb76434d2634514fff836985301ab5'

DELETE
                `newsletter_users`
            FROM
                `newsletter_users`
                INNER JOIN `newsletter_unsubscribed` ON `newsletter_users`.`UserKey` = `newsletter_unsubscribed`.`ID`
            WHERE
                `newsletter_users`.`SendID` = 11
# [18-Jan-2024 12:15:02] /techco/www/tNw2sPa4q/bg/newsletter/1.html 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `URLLabel`,
                `Title`,
                `Content`
            FROM
                `newsletter`
            WHERE
                `ID` = 1 AND
                `Language` = 'bg'
            LIMIT 1

SELECT
                `newsletter_send`.`ID` AS `SendID`,
                `newsletter_send`.`NewsletterID`,
                `newsletter_send`.`PostDate`,
                `newsletter_send`.`Subject`,
                COUNT(`newsletter_users`.`UserKey`) AS `Subscribers`,
                COUNT(CASE WHEN `newsletter_users`.`SendKey` = '' THEN 1 END) AS `Progress`,
                SUM(`newsletter_users`.`Sent`) AS `Sent`,
                SUM(`newsletter_users`.`Opened`) AS `Opened`,
                SUM(`newsletter_users`.`Clicked`) AS `Clicked`
            FROM
                `newsletter`
                INNER JOIN `newsletter_send` ON
                    `newsletter`.`ID` = `newsletter_send`.`NewsletterID` AND
                    `newsletter`.`Language` = `newsletter_send`.`Language`
                LEFT JOIN `newsletter_users` ON `newsletter_users`.`SendID` = `newsletter_send`.`ID`
            WHERE
                `newsletter_send`.`NewsletterID` = 1 AND
                `newsletter`.`Language` = 'bg'
            GROUP BY
                `newsletter_send`.`ID`
            ORDER BY `PostDate` DESC
# [18-Jan-2024 12:15:04] /techco/www/tNw2sPa4q/bg/ajax/newsletter/form/send/1.html?_=1705572905861 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `URLLabel`,
                `Title`,
                `Content`
            FROM
                `newsletter`
            WHERE
                `ID` = 1 AND
                `Language` = 'bg'
            LIMIT 1

SELECT DISTINCT `ClientGroup` FROM `newsletter_subscribers` ORDER BY `ClientGroup` ASC
# [18-Jan-2024 12:15:14] /techco/www/tNw2sPa4q/bg/ajax/newsletter/addsend/1.html?_=1705572915283 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `URLLabel`,
                `Title`,
                `Content`
            FROM
                `newsletter`
            WHERE
                `ID` = 1 AND
                `Language` = 'bg'
            LIMIT 1

SELECT * FROM `newsletter_send` LIMIT 1

SHOW COLUMNS FROM `newsletter_send`

INSERT INTO `newsletter_send` SET `Language` = 'bg', `NewsletterID` = '1', `PostDate` = '2024-01-18 12:15:14', `Subject` = 'test', `Content` = '<h1>test</h1><div>sdfasd fasd fasdfasdfasdf <a href="https://maxgraphic.bg">asdf</a></div><div><img src="/techco/www/uf/newsletter/4975425074/i_teslax1.jpg"></div>'

SELECT * FROM `newsletter_users` LIMIT 1

SHOW COLUMNS FROM `newsletter_users`

REPLACE INTO `newsletter_users` SET `SendID` = 12, `UserKey` = '53a7c0e5c48bc7fa6824548c1ddaf4f33d4c046d6aa89b45add085813b886a67', `Data` = 'bRHfPc8YWAVCfFP9qmC1aRU9wKg5f62YC33DDKoJjj8QLUdIhZkavTFQjDhSssPrQkbyQ4Ikjw3TuQbkmJ9pb19vwc04mjeSFQoy9k9AnEYediOq4h4A3Kj3BSmtwCep', `SendKey` = '34ed45856f0787648d30727ca9831ae6'

DELETE
                `newsletter_users`
            FROM
                `newsletter_users`
                INNER JOIN `newsletter_unsubscribed` ON `newsletter_users`.`UserKey` = `newsletter_unsubscribed`.`ID`
            WHERE
                `newsletter_users`.`SendID` = 12

SELECT COUNT(*) FROM `newsletter_users` WHERE `SendID` = 12

SELECT COUNT(*) FROM `newsletter_users` WHERE `SendID` = 12 AND `Sent` = 1
# [18-Jan-2024 12:15:14] /techco/www/tNw2sPa4q/bg/ajax/newsletter/send/34ed45856f0787648d30727ca9831ae6/12.html?_=1705572915354 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `newsletter_send`.`Subject`,
                `newsletter_send`.`Content`,
                `newsletter_users`.`UserKey`,
                `newsletter_users`.`Data`,
                `newsletter`.`URLLabel`
            FROM
                `newsletter_users`
                INNER JOIN `newsletter_send` ON `newsletter_send`.`ID` = `newsletter_users`.`SendID`
                INNER JOIN `newsletter` ON
                    `newsletter_send`.`NewsletterID` = `newsletter`.`ID` AND
                    `newsletter_send`.`Language` = `newsletter`.`Language`
            WHERE
                `newsletter_users`.`Sent` = 0 AND
                `newsletter_users`.`SendKey` = '34ed45856f0787648d30727ca9831ae6' AND
                `newsletter_send`.`ID` = 12 AND
                `newsletter_send`.`Language` = 'bg'
            LIMIT 1

UPDATE
                    `newsletter_users`
                SET
                    `SendKey` = ''
                WHERE
                    `SendID` = 12 AND
                    `UserKey` = '53a7c0e5c48bc7fa6824548c1ddaf4f33d4c046d6aa89b45add085813b886a67'
                LIMIT 1

UPDATE
                `newsletter_users`
            SET
                `Sent` = 1
            WHERE
                `SendID` = 12 AND
                `UserKey` = '53a7c0e5c48bc7fa6824548c1ddaf4f33d4c046d6aa89b45add085813b886a67'
            LIMIT 1
# [18-Jan-2024 12:15:15] /techco/www/tNw2sPa4q/bg/ajax/newsletter/send/34ed45856f0787648d30727ca9831ae6/12.html?_=1705572916896 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `newsletter_send`.`Subject`,
                `newsletter_send`.`Content`,
                `newsletter_users`.`UserKey`,
                `newsletter_users`.`Data`,
                `newsletter`.`URLLabel`
            FROM
                `newsletter_users`
                INNER JOIN `newsletter_send` ON `newsletter_send`.`ID` = `newsletter_users`.`SendID`
                INNER JOIN `newsletter` ON
                    `newsletter_send`.`NewsletterID` = `newsletter`.`ID` AND
                    `newsletter_send`.`Language` = `newsletter`.`Language`
            WHERE
                `newsletter_users`.`Sent` = 0 AND
                `newsletter_users`.`SendKey` = '34ed45856f0787648d30727ca9831ae6' AND
                `newsletter_send`.`ID` = 12 AND
                `newsletter_send`.`Language` = 'bg'
            LIMIT 1
# [18-Jan-2024 12:15:43] /techco/www/tNw2sPa4q/bg/newsletter/1.html 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT
                `URLLabel`,
                `Title`,
                `Content`
            FROM
                `newsletter`
            WHERE
                `ID` = 1 AND
                `Language` = 'bg'
            LIMIT 1

SELECT
                `newsletter_send`.`ID` AS `SendID`,
                `newsletter_send`.`NewsletterID`,
                `newsletter_send`.`PostDate`,
                `newsletter_send`.`Subject`,
                COUNT(`newsletter_users`.`UserKey`) AS `Subscribers`,
                COUNT(CASE WHEN `newsletter_users`.`SendKey` = '' THEN 1 END) AS `Progress`,
                SUM(`newsletter_users`.`Sent`) AS `Sent`,
                SUM(`newsletter_users`.`Opened`) AS `Opened`,
                SUM(`newsletter_users`.`Clicked`) AS `Clicked`
            FROM
                `newsletter`
                INNER JOIN `newsletter_send` ON
                    `newsletter`.`ID` = `newsletter_send`.`NewsletterID` AND
                    `newsletter`.`Language` = `newsletter_send`.`Language`
                LEFT JOIN `newsletter_users` ON `newsletter_users`.`SendID` = `newsletter_send`.`ID`
            WHERE
                `newsletter_send`.`NewsletterID` = 1 AND
                `newsletter`.`Language` = 'bg'
            GROUP BY
                `newsletter_send`.`ID`
            ORDER BY `PostDate` DESC
# [18-Jan-2024 12:15:50] /techco/www/tNw2sPa4q/bg/newsletter/log/12.html 167.99.142.201

set names utf8

SELECT
                                `ID`
                            FROM
                                `users`
                            WHERE
                                `ID` = 1 AND
                                CRC32(`UserKey`) = 1935110548 AND
                                RIGHT(`UserKey`, 1) = 2
                            LIMIT 1

SELECT `PostDate`, `Subject` FROM `newsletter_send` WHERE `ID` = 12 LIMIT 1

SELECT
                `Data`,
                `Sent`,
                `Opened`,
                `Links`,
                `SendKey`
            FROM
                `newsletter_users`
            WHERE
                `SendID` = 12
         LIMIT 0, 30

SELECT COUNT(*) AS NumRows FROM (
            SELECT
                `Data`,
                `Sent`,
                `Opened`,
                `Links`,
                `SendKey`
            FROM
                `newsletter_users`
            WHERE
                `SendID` = 12
        ) AS CountTable
