# [29-Nov-2022 16:24:50] /photonics/tickets/bg/projections.html 167.99.142.201

set names utf8

SELECT
                MAX(`Monday`) AS `1`,
                MAX(`Tuesday`) AS `2`,
                MAX(`Wednesday`) AS `3`,
                MAX(`Thursday`) AS `4`,
                MAX(`Friday`) AS `5`,
                MAX(`Saturday`) AS `6`,
                MAX(`Sunday`) AS `7`
            FROM
                `projections`
         WHERE `Visible` = 1

SELECT
	        	*
	        FROM
	        	`projections`
            WHERE
                `Tuesday` != ''
         AND `Visible` = 1 ORDER BY `PostDate` ASC
# [29-Nov-2022 16:24:51] /photonics/tickets/bg/orders/1.html?dt=202211291130 167.99.142.201

set names utf8

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'months'
             ORDER BY
                `labels`.`Label` ASC

SELECT
                *
	        FROM
	        	`projections`
	    	WHERE
	    		`ID` = 1
         LIMIT 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202211291130 AND
                `OrderType` & 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202211291130 AND
                `OrderType` & 1

SELECT
                `Price`,
                `Price2`,
                `Price3`,
                `Price4`
	        FROM
	        	`projections`
	    	WHERE
	    		`ID` = 1
         AND `Visible` = 1 LIMIT 1

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'orders'
             ORDER BY
                `labels`.`Label` ASC
# [29-Nov-2022 16:24:54] /photonics/tickets/bg/ajax/orders/submit.html?_=1669731894979 167.99.142.201

set names utf8

SELECT
                    `Sale` + `Reserve` AS `All`
    	        FROM
    	        	`projections`
    	    	WHERE
    	    		`ID` = 1 AND
                    `Visible` = 1
                 LIMIT 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202211291130 AND
                `OrderType` & 1

SELECT * FROM `orders` LIMIT 1

SHOW COLUMNS FROM `orders`

INSERT INTO `orders` SET `PostDate` = '2022-11-29 16:24:54', `LastUpdate` = '2022-11-29 16:24:54', `ProjectionID` = '1', `Data` = 'WptUD8HjEk0qu5cf0EKS9teKu_toqMYGL7VsGiIbHtQT_hqGFo9_3XYJi4oWK9e8ix35glhiL2FC4IfAizlimbeoR30EoUzaczysJxQ0yzvXAV-dIq8-c0g7OknNoqNjLMYczHSfvSDqYJHToudEgXf5trxxhJQL0cycyWT03wlYAeBki2qKMeJV-I_GWDsxoNggJBlawWYLMkpJnRnKow', `SearchKey` = 'wofCuMOWwqPDmMKkwrPCtsKHwrnC', `SortName` = '10821072', `Status` = 16

SELECT
                `Price`,
                `Price2`,
                `Price3`,
                `Price4`
	        FROM
	        	`projections`
	    	WHERE
	    		`ID` = 1
         AND `Visible` = 1 LIMIT 1

INSERT INTO `tickets`
            (`ID`, `PostDate`, `LastUpdate`, `OrderID`, `DateTime`, `OrderType`, `TicketType`, `Price`, `Status`) VALUES
            (NULL, NOW(), NOW(), 143, 202211291130, 1, 1, 10.00, 0)
# [29-Nov-2022 16:24:54] /photonics/tickets/bg/orders/preview/143.html 167.99.142.201

set names utf8

SELECT
                `Data`,
                `Status`
            FROM
                `orders`
            WHERE
                `ID` = 143
            LIMIT 1

SELECT
                `tickets`.*,
                `projections`.`Title`
            FROM
                `tickets`
                INNER JOIN `orders` ON `tickets`.`OrderID` = `orders`.`ID`
                INNER JOIN `projections` ON `orders`.`ProjectionID` = `projections`.`ID`
            WHERE
                `tickets`.`OrderID` = 143
            ORDER BY
                `tickets`.`ID` ASC

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'months'
             ORDER BY
                `labels`.`Label` ASC

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'orders'
             ORDER BY
                `labels`.`Label` ASC
# [29-Nov-2022 16:48:12] /photonics/tickets/bg/projections.html 167.99.142.201

set names utf8

SELECT
                MAX(`Monday`) AS `1`,
                MAX(`Tuesday`) AS `2`,
                MAX(`Wednesday`) AS `3`,
                MAX(`Thursday`) AS `4`,
                MAX(`Friday`) AS `5`,
                MAX(`Saturday`) AS `6`,
                MAX(`Sunday`) AS `7`
            FROM
                `projections`
         WHERE `Visible` = 1

SELECT
	        	*
	        FROM
	        	`projections`
            WHERE
                `Tuesday` != ''
         AND `Visible` = 1 ORDER BY `PostDate` ASC
# [29-Nov-2022 16:48:14] /photonics/tickets/bg/projections.html?d=2022-11-30 167.99.142.201

set names utf8

SELECT
                MAX(`Monday`) AS `1`,
                MAX(`Tuesday`) AS `2`,
                MAX(`Wednesday`) AS `3`,
                MAX(`Thursday`) AS `4`,
                MAX(`Friday`) AS `5`,
                MAX(`Saturday`) AS `6`,
                MAX(`Sunday`) AS `7`
            FROM
                `projections`
         WHERE `Visible` = 1

SELECT
	        	*
	        FROM
	        	`projections`
            WHERE
                `Wednesday` != ''
         AND `Visible` = 1 ORDER BY `PostDate` ASC
# [29-Nov-2022 16:48:15] /photonics/tickets/bg/projections.html?d=2022-12-01 167.99.142.201

set names utf8

SELECT
                MAX(`Monday`) AS `1`,
                MAX(`Tuesday`) AS `2`,
                MAX(`Wednesday`) AS `3`,
                MAX(`Thursday`) AS `4`,
                MAX(`Friday`) AS `5`,
                MAX(`Saturday`) AS `6`,
                MAX(`Sunday`) AS `7`
            FROM
                `projections`
         WHERE `Visible` = 1

SELECT
	        	*
	        FROM
	        	`projections`
            WHERE
                `Thursday` != ''
         AND `Visible` = 1 ORDER BY `PostDate` ASC
# [29-Nov-2022 16:48:17] /photonics/tickets/bg/orders/1.html?dt=202212011030 167.99.142.201

set names utf8

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'months'
             ORDER BY
                `labels`.`Label` ASC

SELECT
                *
	        FROM
	        	`projections`
	    	WHERE
	    		`ID` = 1
         LIMIT 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202212011030 AND
                `OrderType` & 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202212011030 AND
                `OrderType` & 2

SELECT
                `Price`,
                `Price2`,
                `Price3`,
                `Price4`
	        FROM
	        	`projections`
	    	WHERE
	    		`ID` = 1
         AND `Visible` = 1 LIMIT 1

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'orders'
             ORDER BY
                `labels`.`Label` ASC
# [29-Nov-2022 16:48:21] /photonics/tickets/bg/orders/resv/1.html?dt=202212011030 167.99.142.201

set names utf8

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'months'
             ORDER BY
                `labels`.`Label` ASC

SELECT
                *
	        FROM
	        	`projections`
	    	WHERE
	    		`ID` = 1
         LIMIT 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202212011030 AND
                `OrderType` & 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202212011030 AND
                `OrderType` & 2

SELECT
                `orders`.`ID`,
                `orders`.`PostDate`,
                COUNT(`tickets`.`ID`) AS `All`,
                SUM(`tickets`.`Status`) AS `Used`,
                SUM(`tickets`.`Price`) AS `TotalPrice`
            FROM
                `orders`
                INNER JOIN `tickets` ON `orders`.`ID` = `tickets`.`OrderID`
            WHERE
                `orders`.`ProjectionID` = 1 AND
                `tickets`.`DateTime` = 202212011030 AND
                `tickets`.`OrderType` = 2
            GROUP BY
                `orders`.`ID`
             ORDER BY
                `orders`.`PostDate` ASC
# [29-Nov-2022 16:48:23] /photonics/tickets/bg/orders/1.html?dt=202212011030 167.99.142.201

set names utf8

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'months'
             ORDER BY
                `labels`.`Label` ASC

SELECT
                *
	        FROM
	        	`projections`
	    	WHERE
	    		`ID` = 1
         LIMIT 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202212011030 AND
                `OrderType` & 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202212011030 AND
                `OrderType` & 2

SELECT
                `Price`,
                `Price2`,
                `Price3`,
                `Price4`
	        FROM
	        	`projections`
	    	WHERE
	    		`ID` = 1
         AND `Visible` = 1 LIMIT 1

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'orders'
             ORDER BY
                `labels`.`Label` ASC
# [29-Nov-2022 16:48:24] /photonics/tickets/bg/orders/sales/1.html?dt=202212011030 167.99.142.201

set names utf8

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'months'
             ORDER BY
                `labels`.`Label` ASC

SELECT
                *
	        FROM
	        	`projections`
	    	WHERE
	    		`ID` = 1
         LIMIT 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202212011030 AND
                `OrderType` & 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202212011030 AND
                `OrderType` & 2

SELECT
                `orders`.`ID`,
                `orders`.`PostDate`,
                COUNT(`tickets`.`ID`) AS `All`,
                SUM(`tickets`.`Status`) AS `Used`,
                SUM(`tickets`.`Price`) AS `TotalPrice`
            FROM
                `orders`
                INNER JOIN `tickets` ON `orders`.`ID` = `tickets`.`OrderID`
            WHERE
                `orders`.`ProjectionID` = 1 AND
                `tickets`.`DateTime` = 202212011030 AND
                `tickets`.`OrderType` = 1
            GROUP BY
                `orders`.`ID`
             ORDER BY
                `orders`.`PostDate` ASC
# [29-Nov-2022 16:48:26] /photonics/tickets/bg/orders/sales/1.html?dt=202212011030 167.99.142.201

set names utf8

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'months'
             ORDER BY
                `labels`.`Label` ASC

SELECT
                *
	        FROM
	        	`projections`
	    	WHERE
	    		`ID` = 1
         LIMIT 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202212011030 AND
                `OrderType` & 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202212011030 AND
                `OrderType` & 2

SELECT
                `orders`.`ID`,
                `orders`.`PostDate`,
                COUNT(`tickets`.`ID`) AS `All`,
                SUM(`tickets`.`Status`) AS `Used`,
                SUM(`tickets`.`Price`) AS `TotalPrice`
            FROM
                `orders`
                INNER JOIN `tickets` ON `orders`.`ID` = `tickets`.`OrderID`
            WHERE
                `orders`.`ProjectionID` = 1 AND
                `tickets`.`DateTime` = 202212011030 AND
                `tickets`.`OrderType` = 1
            GROUP BY
                `orders`.`ID`
             ORDER BY
                `orders`.`PostDate` ASC
# [29-Nov-2022 16:48:27] /photonics/tickets/bg/orders/1.html?dt=202212011030 167.99.142.201

set names utf8

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'months'
             ORDER BY
                `labels`.`Label` ASC

SELECT
                *
	        FROM
	        	`projections`
	    	WHERE
	    		`ID` = 1
         LIMIT 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202212011030 AND
                `OrderType` & 1

SELECT
                COUNT(`ID`)
            FROM
                `tickets`
            WHERE
                `DateTime` = 202212011030 AND
                `OrderType` & 2

SELECT
                `Price`,
                `Price2`,
                `Price3`,
                `Price4`
	        FROM
	        	`projections`
	    	WHERE
	    		`ID` = 1
         AND `Visible` = 1 LIMIT 1

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'orders'
             ORDER BY
                `labels`.`Label` ASC
