# [25-Jan-2023 15:34:20] /unicat/root/ 167.99.142.201

set names utf8

SELECT CONCAT_WS('/', `UploadID`, `Image`) AS `BackgroundURL`
            FROM
                `background`
            WHERE
                `Visible` = 1
            ORDER BY `LastUpdate` DESC
            LIMIT 1

SELECT
				`products`.`ID`
			FROM
				`products`
				INNER JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
				INNER JOIN `groups` ON `product_groups`.`GroupID` = `groups`.`ID`
				INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
			WHERE
				(`PromoStart` IS NOT NULL OR `PromoEnd` IS NOT NULL) AND
				(`PromoStart` IS NULL OR `PromoStart` <= NOW()) AND
				(`PromoEnd` IS NULL OR `PromoEnd` >= NOW()) AND
				`product_texts`.`Language` = 'bg' AND
				`products`.`Visible` = 1 AND
				`groups`.`Visible` = 1
			LIMIT 1

SELECT
                `G1`.`ID`,
                `G1`.`UploadID`,
                `G1`.`Image`,
                `G1`.`ID`,
                `G1`.`ParentID`,
                `G1`.`Color`,
                `GT1`.`MenuLabel`,
                `GT1`.`Title`,
                `GT1`.`URLLabel`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                `G2`.`ParentID` AS `ParentNodeID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `G1`.`ParentID` = 0 AND
                `G1`.`Visible` = 1 AND
                `GT1`.`Language` = 'bg'
            GROUP BY
                `G1`.`ID`
            ORDER BY
                `G1`.`PostDate` ASC

SELECT
               *
            FROM
                `products`
                INNER JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `product_texts`.`Language` = 'bg' AND
                `products`.`selected` = 1
            GROUP BY `products`.`ID`
            ORDER BY `products`.`PostDate` DESC
# [25-Jan-2023 15:34:20] /unicat/root/bg/ajax/prices.html?_=1674653734130 167.99.142.201

set names utf8

SELECT `Token` FROM `token` WHERE `Expires` > CURDATE()

DELETE FROM `token`

INSERT INTO `token` (`ID`, `Token`, `Expires`) VALUES (NULL, 'gbp9MjRdA7BV4J7KveLG7A7kJnlJ6k5-Wlel-DUF10l8_tsOVq7W47Vt0R5xzn8mraWAepOiuscJmGp0dFkdS-EN6DODTwvzPnHQjC8PYsT5QUsnVqSuIUnLy27Qlsg6eCqL4v7KuNr0evLzIoCh1lSKiqjXT0YC-T1f-XvgvlUgR6_Tmpwd-GJZh0boKxogEMa5EH8Z2eRrdH139XEWCU7cRwyeOmVjcI8e3aBh8XpjTKIKa2ycEgHHoJO1fnsk3qh_dvLAKnelHRj7LXBEYRPIx7EkSKNmp0PW1Nk5vMQrHFqKhi7HWUXKWS42rfm3GyY25Sg4ohbsOVClAzLuDjMCHQMBcnjuOokCRSi3l9iBwjttx0UtXZzolYw6Zk-eBGvwv2yE4A4K-9Y6_QBu3TGNNwVVp_iDcMlneyZF1EnBYkAgxCpZnC3wx8X5uQ6XMQtQcr4HeS0QQn7frHm0IZHc8yXF74cCcNRSEYhmXGG08aLclcp8Seb1_y8lQZppNthf65qyup4jDapVpFBstQ', '2023-02-08')

SELECT `RefNumber` FROM `products` WHERE `RefID` = '0990822-serwo' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '54267-jbm' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'super-conc-screen-wash-21-1l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'rowe-antifreeze-g12-15l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '0970816-serwo-gmbh' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'emergency-car-kit' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'os-h7-12v-55w-nb-x2' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '036164' AND `Visible` = 1 LIMIT 1
# [25-Jan-2023 15:34:39] /unicat/root/bg/groups/части-за-камиони.html 167.99.142.201

set names utf8

SELECT
                    `GroupID`
                FROM
                    `group_texts`
                WHERE
                    `URLLabel` = 'части-за-камиони' AND
                    `Language` = 'bg'
                LIMIT 1

SELECT
                `G1`.`ID`,
                `GT1`.`MenuLabel`,
                `GT1`.`Title`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                `GT1`.`URLLabel`,
                (SELECT `ID` FROM `groups` WHERE `ParentID` = `G1`.`ID` LIMIT 1) AS `ChildID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `GT1`.`Language` = 'bg' AND
                `G1`.`ID` IN (
                    WITH RECURSIVE `cte` (`ParentID`) AS (
                        SELECT `ID` FROM `groups` WHERE `ID` = 52
                        UNION ALL
                        SELECT `groups`.`ParentID` FROM `groups` INNER JOIN `cte` ON `groups`.`ID` = `cte`.`ParentID`
                    )
                    SELECT `cte`.`ParentID` FROM `cte`
                )
            GROUP BY
                `G1`.`ID`

SELECT CONCAT_WS('/', `UploadID`, `Image`) AS `BackgroundURL`
            FROM
                `background`
            WHERE
                `Visible` = 1
            ORDER BY `LastUpdate` DESC
            LIMIT 1

SELECT
                `G1`.`ID`,
                `G1`.`UploadID`,
                `G1`.`Image`,
                `G1`.`ID`,
                `G1`.`ParentID`,
                `G1`.`Color`,
                `GT1`.`MenuLabel`,
                `GT1`.`Title`,
                `GT1`.`URLLabel`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                `G2`.`ParentID` AS `ParentNodeID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `G1`.`ParentID` = 52 AND
                `G1`.`Visible` = 1 AND
                `GT1`.`Language` = 'bg'
            GROUP BY
                `G1`.`ID`
            ORDER BY
                `G1`.`PostDate` ASC
# [25-Jan-2023 15:34:51] /unicat/root/bg/groups/части-за-камиони/светлини-за-товарни.html 167.99.142.201

set names utf8

SELECT
                    `GT1`.`GroupID`
                FROM
                    `group_texts` AS `GT1`
                    INNER JOIN `groups` ON `groups`.`ID` = `GT1`.`GroupID`
                    INNER JOIN `group_texts` AS `GT2` ON `groups`.`ParentID` = `GT2`.`GroupID`
                WHERE
                    `GT1`.`URLLabel` = 'светлини-за-товарни' AND
                    `GT2`.`URLLabel` = 'части-за-камиони' AND
                    `GT1`.`Language` = 'bg' AND
                    `GT2`.`Language` = 'bg'
                LIMIT 1

SELECT
                `G1`.`ID`,
                `GT1`.`MenuLabel`,
                `GT1`.`Title`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                `GT1`.`URLLabel`,
                (SELECT `ID` FROM `groups` WHERE `ParentID` = `G1`.`ID` LIMIT 1) AS `ChildID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `GT1`.`Language` = 'bg' AND
                `G1`.`ID` IN (
                    WITH RECURSIVE `cte` (`ParentID`) AS (
                        SELECT `ID` FROM `groups` WHERE `ID` = 827
                        UNION ALL
                        SELECT `groups`.`ParentID` FROM `groups` INNER JOIN `cte` ON `groups`.`ID` = `cte`.`ParentID`
                    )
                    SELECT `cte`.`ParentID` FROM `cte`
                )
            GROUP BY
                `G1`.`ID`

SELECT CONCAT_WS('/', `UploadID`, `Image`) AS `BackgroundURL`
            FROM
                `background`
            WHERE
                `Visible` = 1
            ORDER BY `LastUpdate` DESC
            LIMIT 1

SELECT
                `G1`.`ID`,
                `G1`.`UploadID`,
                `G1`.`Image`,
                `G1`.`ID`,
                `G1`.`ParentID`,
                `G1`.`Color`,
                `GT1`.`MenuLabel`,
                `GT1`.`Title`,
                `GT1`.`URLLabel`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                `G2`.`ParentID` AS `ParentNodeID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `G1`.`ParentID` = 827 AND
                `G1`.`Visible` = 1 AND
                `GT1`.`Language` = 'bg'
            GROUP BY
                `G1`.`ID`
            ORDER BY
                `G1`.`PostDate` ASC
# [25-Jan-2023 15:34:54] /unicat/root/bg/products/светлини-за-товарни/задни-светлини.html 167.99.142.201

set names utf8

SELECT
                    `GT1`.`GroupID`
                FROM
                    `group_texts` AS `GT1`
                    INNER JOIN `groups` ON `groups`.`ID` = `GT1`.`GroupID`
                    INNER JOIN `group_texts` AS `GT2` ON `groups`.`ParentID` = `GT2`.`GroupID`
                WHERE
                    `GT1`.`URLLabel` = 'задни-светлини' AND
                    `GT2`.`URLLabel` = 'светлини-за-товарни' AND
                    `GT1`.`Language` = 'bg' AND
                    `GT2`.`Language` = 'bg'
                LIMIT 1

SELECT
                `G1`.`ID`,
                `GT1`.`MenuLabel`,
                `GT1`.`Title`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                `GT1`.`URLLabel`,
                (SELECT `ID` FROM `groups` WHERE `ParentID` = `G1`.`ID` LIMIT 1) AS `ChildID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `GT1`.`Language` = 'bg' AND
                `G1`.`ID` IN (
                    WITH RECURSIVE `cte` (`ParentID`) AS (
                        SELECT `ID` FROM `groups` WHERE `ID` = 892
                        UNION ALL
                        SELECT `groups`.`ParentID` FROM `groups` INNER JOIN `cte` ON `groups`.`ID` = `cte`.`ParentID`
                    )
                    SELECT `cte`.`ParentID` FROM `cte`
                )
            GROUP BY
                `G1`.`ID`

SELECT
                `G1`.`ID`,
                `G1`.`ParentID`,
                `GT1`.`MenuLabel`,
                `GT1`.`URLLabel`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                (SELECT `ID` FROM `groups` WHERE `ParentID` = `G1`.`ID` LIMIT 1) AS `ChildID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `G1`.`Visible` = 1 AND
                `GT1`.`Language` = 'bg'

            GROUP BY
                `G1`.`ID`
            ORDER BY
                `G1`.`ParentID` ASC,
                `G1`.`PostDate` ASC

SELECT
                `params`.`ID`
            FROM
                `product_groups`
                INNER JOIN `product_params` ON `product_groups`.`ProductID` = `product_params`.`ProductID`
                INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
            WHERE
                `product_groups`.`GroupID` = 892 AND
                `params`.`FilterType` > 0 AND
                `params`.`Required` = 1
            GROUP BY
                `params`.`ID`
            ORDER BY
                `params`.`PostDate` ASC

SELECT
               `products`.`ID`,
               `products`.`UploadID`,
               `products`.`RefNumber`,
               `products`.`RefID`,
               `products`.`Brand`,
               `products`.`Gallery`,
               `product_texts`.`Title`,
               `product_texts`.`URLLabel`,
               (
                    SELECT
                        GROUP_CONCAT(DISTINCT CONCAT_WS('][', `product_params`.`ParamID`, `product_params`.`ParamValue`) SEPARATOR '|') AS `Params`
                    FROM
                        `product_params`
                        INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                    WHERE
                        `product_params`.`ProductID` = `products`.`ID` AND
                        `params`.`FilterType` IN (1,2,3) AND
                        `params`.`Code` != 'brand'
                    GROUP BY
                        `product_params`.`ProductID`
               ) AS `Params`,
               (
                    SELECT
                        GROUP_CONCAT(DISTINCT CONCAT_WS('-', `product_params`.`ParamID`, `product_params`.`ParamValue`) SEPARATOR '|') AS `Params`
                    FROM
                        `product_params`
                        INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                    WHERE
                        `product_params`.`ProductID` = `products`.`ID` AND
                        `params`.`FilterType` IN (4,5) AND
                        `params`.`Code` != 'brand'
                    GROUP BY
                        `product_params`.`ProductID`
               ) AS `Ranges`
            FROM
                `products`
                INNER JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
                INNER JOIN `groups` ON `product_groups`.`GroupID` = `groups`.`ID`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
                
            WHERE
                `product_groups`.`GroupID` = 892 AND
                `product_texts`.`Language` = 'bg' AND
                `products`.`Visible` = 1 AND
                `groups`.`Visible` = 1
            GROUP BY
                `products`.`ID`
            ORDER BY
                `products`.`PostDate` ASC

SET SESSION group_concat_max_len = 10240

SELECT
                `param_texts`.`Title`,
                `param_texts`.`Metric`,
                `params`.`ID`,
                `params`.`UploadID`,
                `params`.`FilterType`,
                `params`.`ImgValues`,
                `params`.`Prefix`,
                `params`.`Code`,
                GROUP_CONCAT(DISTINCT `PPV`.`ParamValue` SEPARATOR '][') AS `Values`
            FROM
                `products`
                INNER JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
                INNER JOIN `product_params` AS `PPV` ON `products`.`ID` = `PPV`.`ProductID`
                INNER JOIN `params` ON `params`.`ID` = `PPV`.`ParamID`
                INNER JOIN `param_texts` ON `params`.`ID` = `param_texts`.`ParamID`
                
            WHERE
                `product_groups`.`GroupID` = 892 AND
                `params`.`FilterType` > 0 AND
                `params`.`Required` = 0
            GROUP BY
                `params`.`ID`
            ORDER BY
                `params`.`PostDate` ASC
# [25-Jan-2023 15:34:54] /unicat/root/bg/ajax/prices.html?_=1674653768608 167.99.142.201

set names utf8

SELECT `Token` FROM `token` WHERE `Expires` > CURDATE()

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-002l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-002r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '1060-was' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '1062-was' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-002al' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-002l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-002ar' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '206152-sampa' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '206153-sampa' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-028' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-027' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-026' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-025' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-023a-24' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-63-024l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-63-024r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-63-002l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-63-002r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-57-003l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-57-003r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-001l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-001r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-001l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-001r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-032ahl' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-032ahr-24' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-019l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-019r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-007l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-007r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-003l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-003r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'm611437' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'm611436' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '6606872' AND `Visible` = 1 LIMIT 1
# [25-Jan-2023 15:35:08] /unicat/root/bg/ajax/prices.html?_=1674653782324 167.99.142.201

set names utf8

SELECT `Token` FROM `token` WHERE `Expires` > CURDATE()

SELECT `RefNumber` FROM `products` WHERE `RefID` = '6606873' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '0350ll' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '0350lr' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '0350lq1l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '0350lq1r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '0230l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-003l' AND `Visible` = 1 LIMIT 1
# [25-Jan-2023 15:35:09] /unicat/root/bg/ajax/prices.html?_=1674653783354 167.99.142.201

set names utf8

SELECT `Token` FROM `token` WHERE `Expires` > CURDATE()

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-003r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-009l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-009r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'ft-110' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '098212368' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'd13817-vignal' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'd13816-vignal' AND `Visible` = 1 LIMIT 1
# [25-Jan-2023 15:35:10] /unicat/root/bg/ajax/prices.html?_=1674653783437 167.99.142.201

set names utf8

SELECT `Token` FROM `token` WHERE `Expires` > CURDATE()

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'd12340-vignal' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'd12341-vignal' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '500930-vignal' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '500940-vignal' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '169400-vignal' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '169410-vignal' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '169420-vignal' AND `Visible` = 1 LIMIT 1
# [25-Jan-2023 15:35:49] /unicat/root/nRqioDzp/bg/ajax/users/form/login.html?_=1674653822776 167.99.142.201

set names utf8

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Module` = 'error' AND
                `Language` = 'bg'
             ORDER BY
                `labels`.`Label` ASC
# [25-Jan-2023 15:35:52] /unicat/root/nRqioDzp/bg/ajax/users/login.html?_=1674653825981 167.99.142.201

set names utf8

SELECT `ID`, `UserKey` FROM `users` WHERE `UserKey` LIKE 'w4vCvcOjw6LCjcOZw43DrMK6w4rDjcOKw43DlMK9wp3CtsK8%' LIMIT 1
# [25-Jan-2023 15:35:52] /unicat/root/nRqioDzp/ 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
               *
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `Language` = 'bg'
         ORDER BY `products`.`LastUpdate` ASC LIMIT 0, 100

SELECT COUNT(*) AS NumRows FROM (
            SELECT
               *
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `Language` = 'bg'
         ORDER BY `products`.`LastUpdate` ASC) AS CountTable
# [25-Jan-2023 15:36:09] /unicat/root/bg/products/892/td0252002l.html 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
               `products`.*,
               `product_texts`.*
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
                INNER JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
            WHERE
                `product_texts`.`URLLabel` = 'td0252002l' AND
                `product_texts`.`Language` = 'bg' AND
                `product_groups`.`GroupID` = 892
            LIMIT 1

SELECT
                `G1`.`ID`,
                `GT1`.`MenuLabel`,
                `GT1`.`Title`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                `GT1`.`URLLabel`,
                (SELECT `ID` FROM `groups` WHERE `ParentID` = `G1`.`ID` LIMIT 1) AS `ChildID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `GT1`.`Language` = 'bg' AND
                `G1`.`ID` IN (
                    WITH RECURSIVE `cte` (`ParentID`) AS (
                        SELECT `ID` FROM `groups` WHERE `ID` = 892
                        UNION ALL
                        SELECT `groups`.`ParentID` FROM `groups` INNER JOIN `cte` ON `groups`.`ID` = `cte`.`ParentID`
                    )
                    SELECT `cte`.`ParentID` FROM `cte`
                )
            GROUP BY
                `G1`.`ID`

SELECT
                `G1`.`ID`,
                `G1`.`ParentID`,
                `GT1`.`MenuLabel`,
                `GT1`.`URLLabel`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                (SELECT `ID` FROM `groups` WHERE `ParentID` = `G1`.`ID` LIMIT 1) AS `ChildID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `G1`.`Visible` = 1 AND
                `GT1`.`Language` = 'bg'

            GROUP BY
                `G1`.`ID`
            ORDER BY
                `G1`.`ParentID` ASC,
                `G1`.`PostDate` ASC

SELECT
                `params`.`Code`,
                `params`.`UploadID`,
                `params`.`ImgValues`,
                `product_params`.`ParamID`,
                `param_texts`.`Title`,
                `param_texts`.`Metric`,
                `params`.`Prefix`,
                GROUP_CONCAT(`ParamValue` separator '<br />') AS `Values`
            FROM
                `product_params`
                INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                INNER JOIN `param_texts` ON `product_params`.`ParamID` = `param_texts`.`ParamID`
            WHERE
                `product_params`.`ProductID` = 9162 AND
                `param_texts`.`Language` = 'bg'
            GROUP BY
                `product_params`.`ParamID`
            ORDER BY
                `params`.`PostDate` DESC
# [25-Jan-2023 15:36:09] /unicat/root/bg/ajax/users/session.html?_=1674653843041 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1
# [25-Jan-2023 15:36:09] /unicat/root/bg/ajax/prices.html?_=1674653843080 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT `Token` FROM `token` WHERE `Expires` > CURDATE()

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-002l' AND `Visible` = 1 LIMIT 1
# [25-Jan-2023 15:36:14] /unicat/root/nRqioDzp/bg/products/list.html?keyword=ОБОРУДВАНЕ КАБИНА И РЕМАРКЕ 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
               *
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `Language` = 'bg'
         AND (
                                `products`.`RefID` LIKE '%оборудване%кабина%и%ремарке%' OR
                                `products`.`RefNumber` LIKE '%оборудване%кабина%и%ремарке%' OR
                                `products`.`ArtNumber` LIKE '%оборудване%кабина%и%ремарке%' OR
                                `products`.`Brand` LIKE '%оборудване%кабина%и%ремарке%' OR
                                `product_texts`.`Title` LIKE '%оборудване%кабина%и%ремарке%' OR
                                `product_texts`.`Content` LIKE '%оборудване%кабина%и%ремарке%'
                            )
                        
                                ORDER BY CASE
                                    WHEN `products`.`RefNumber` LIKE 'оборудване%кабина%и%ремарке%' THEN 0
                                    WHEN `products`.`ArtNumber` LIKE 'оборудване%кабина%и%ремарке%' THEN 1
                                    WHEN `products`.`Brand` LIKE 'оборудване%кабина%и%ремарке%' THEN 2
                                    WHEN `product_texts`.`Title` LIKE 'оборудване%кабина%и%ремарке%' THEN 3
                                    WHEN `product_texts`.`Title` LIKE '% оборудване%кабина%и%ремарке%' THEN 4
                                    ELSE 5
                                END
                             LIMIT 0, 100

SELECT COUNT(*) AS NumRows FROM (
            SELECT
               *
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `Language` = 'bg'
         AND (
                                `products`.`RefID` LIKE '%оборудване%кабина%и%ремарке%' OR
                                `products`.`RefNumber` LIKE '%оборудване%кабина%и%ремарке%' OR
                                `products`.`ArtNumber` LIKE '%оборудване%кабина%и%ремарке%' OR
                                `products`.`Brand` LIKE '%оборудване%кабина%и%ремарке%' OR
                                `product_texts`.`Title` LIKE '%оборудване%кабина%и%ремарке%' OR
                                `product_texts`.`Content` LIKE '%оборудване%кабина%и%ремарке%'
                            )
                        
                                ORDER BY CASE
                                    WHEN `products`.`RefNumber` LIKE 'оборудване%кабина%и%ремарке%' THEN 0
                                    WHEN `products`.`ArtNumber` LIKE 'оборудване%кабина%и%ремарке%' THEN 1
                                    WHEN `products`.`Brand` LIKE 'оборудване%кабина%и%ремарке%' THEN 2
                                    WHEN `product_texts`.`Title` LIKE 'оборудване%кабина%и%ремарке%' THEN 3
                                    WHEN `product_texts`.`Title` LIKE '% оборудване%кабина%и%ремарке%' THEN 4
                                    ELSE 5
                                END
                            ) AS CountTable
# [25-Jan-2023 15:36:24] /unicat/root/nRqioDzp/bg/ajax/products/form/5979.html?_=1674653858383 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
                `products`.*,
                `product_texts`.*,
                GROUP_CONCAT(`GroupID` SEPARATOR ',') AS `Groups`
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
                LEFT JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
            WHERE
                `products`.`ID` = 5979 AND
                `product_texts`.`Language` = 'bg'
            LIMIT 1

SELECT `ImgValues` FROM `params` WHERE `Code` = 'brand' LIMIT 1

SELECT
                `groups`.`ID`,
                `groups`.`ParentID`,
                `group_texts`.`Title`,
                `group_texts`.`MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg'
            ORDER BY
                `groups`.`ParentID` ASC,
                `groups`.`PostDate` ASC

SELECT
                `groups`.`ID`,
                `groups`.`ParentID`,
                `group_texts`.`Title`,
                `group_texts`.`MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg'
            ORDER BY
                `groups`.`ParentID` ASC,
                `groups`.`PostDate` ASC

SELECT
                    `GroupID`
                FROM
                    `product_groups`
                WHERE
                    `ProductID` = 5979

SELECT
                `MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg' AND
                `groups`.`ID` IN (
                    WITH RECURSIVE `cte` (`ParentID`) AS (
                        SELECT `ID` FROM `groups` WHERE `ID` = 836
                        UNION ALL
                        SELECT `groups`.`ParentID` FROM `groups` INNER JOIN `cte` ON `groups`.`ID` = `cte`.`ParentID`
                    )
                    SELECT `cte`.`ParentID` FROM `cte`
                )

SELECT
                    `param_texts`.`ParamID`,
                    IF(
                        `param_texts`.`Metric` = '',
                        `param_texts`.`Title`,
                        CONCAT_WS(' ', `param_texts`.`Title`, CONCAT('[', `param_texts`.`Metric`, ']'))
                    ) AS `Param`
                FROM
                    `params`
                    INNER JOIN `param_texts` ON `params`.`ID` = `param_texts`.`ParamID`
                WHERE
                    `param_texts`.`Language` = 'bg'
                ORDER BY
                    `param_texts`.`Title` ASC

SELECT
                    `param_texts`.`ParamID`,
                    IF(
                        `param_texts`.`Metric` = '',
                        `param_texts`.`Title`,
                        CONCAT_WS(' ', `param_texts`.`Title`, CONCAT('[', `param_texts`.`Metric`, ']'))
                    ) AS `Param`,
                    `ParamValue`
                FROM
                    `product_params`
                    INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                    INNER JOIN `param_texts` ON `product_params`.`ParamID` = `param_texts`.`ParamID`
                WHERE
                    `product_params`.`ProductID` = 5979 AND
                    `param_texts`.`Language` = 'bg'
                ORDER BY
                    `params`.`PostDate` DESC
# [25-Jan-2023 15:36:33] /unicat/root/nRqioDzp/bg/ajax/products/form/9141.html?_=1674653866710 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
                `products`.*,
                `product_texts`.*,
                GROUP_CONCAT(`GroupID` SEPARATOR ',') AS `Groups`
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
                LEFT JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
            WHERE
                `products`.`ID` = 9141 AND
                `product_texts`.`Language` = 'bg'
            LIMIT 1

SELECT `ImgValues` FROM `params` WHERE `Code` = 'brand' LIMIT 1

SELECT
                `groups`.`ID`,
                `groups`.`ParentID`,
                `group_texts`.`Title`,
                `group_texts`.`MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg'
            ORDER BY
                `groups`.`ParentID` ASC,
                `groups`.`PostDate` ASC

SELECT
                `groups`.`ID`,
                `groups`.`ParentID`,
                `group_texts`.`Title`,
                `group_texts`.`MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg'
            ORDER BY
                `groups`.`ParentID` ASC,
                `groups`.`PostDate` ASC

SELECT
                    `GroupID`
                FROM
                    `product_groups`
                WHERE
                    `ProductID` = 9141

SELECT
                `MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg' AND
                `groups`.`ID` IN (
                    WITH RECURSIVE `cte` (`ParentID`) AS (
                        SELECT `ID` FROM `groups` WHERE `ID` = 339
                        UNION ALL
                        SELECT `groups`.`ParentID` FROM `groups` INNER JOIN `cte` ON `groups`.`ID` = `cte`.`ParentID`
                    )
                    SELECT `cte`.`ParentID` FROM `cte`
                )

SELECT
                    `param_texts`.`ParamID`,
                    IF(
                        `param_texts`.`Metric` = '',
                        `param_texts`.`Title`,
                        CONCAT_WS(' ', `param_texts`.`Title`, CONCAT('[', `param_texts`.`Metric`, ']'))
                    ) AS `Param`
                FROM
                    `params`
                    INNER JOIN `param_texts` ON `params`.`ID` = `param_texts`.`ParamID`
                WHERE
                    `param_texts`.`Language` = 'bg'
                ORDER BY
                    `param_texts`.`Title` ASC

SELECT
                    `param_texts`.`ParamID`,
                    IF(
                        `param_texts`.`Metric` = '',
                        `param_texts`.`Title`,
                        CONCAT_WS(' ', `param_texts`.`Title`, CONCAT('[', `param_texts`.`Metric`, ']'))
                    ) AS `Param`,
                    `ParamValue`
                FROM
                    `product_params`
                    INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                    INNER JOIN `param_texts` ON `product_params`.`ParamID` = `param_texts`.`ParamID`
                WHERE
                    `product_params`.`ProductID` = 9141 AND
                    `param_texts`.`Language` = 'bg'
                ORDER BY
                    `params`.`PostDate` DESC
# [25-Jan-2023 15:36:45] /unicat/root/nRqioDzp/bg/products/list.html?keyword=Стоп L SCANIA 4 (96-04)  167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
               *
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `Language` = 'bg'
         AND (
                                `products`.`RefID` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`RefNumber` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`ArtNumber` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`Brand` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `product_texts`.`Title` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `product_texts`.`Content` LIKE '%стоп%l%scania%4%(96-04)%'
                            )
                        
                                ORDER BY CASE
                                    WHEN `products`.`RefNumber` LIKE 'стоп%l%scania%4%(96-04)%' THEN 0
                                    WHEN `products`.`ArtNumber` LIKE 'стоп%l%scania%4%(96-04)%' THEN 1
                                    WHEN `products`.`Brand` LIKE 'стоп%l%scania%4%(96-04)%' THEN 2
                                    WHEN `product_texts`.`Title` LIKE 'стоп%l%scania%4%(96-04)%' THEN 3
                                    WHEN `product_texts`.`Title` LIKE '% стоп%l%scania%4%(96-04)%' THEN 4
                                    ELSE 5
                                END
                             LIMIT 0, 100

SELECT COUNT(*) AS NumRows FROM (
            SELECT
               *
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `Language` = 'bg'
         AND (
                                `products`.`RefID` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`RefNumber` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`ArtNumber` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`Brand` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `product_texts`.`Title` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `product_texts`.`Content` LIKE '%стоп%l%scania%4%(96-04)%'
                            )
                        
                                ORDER BY CASE
                                    WHEN `products`.`RefNumber` LIKE 'стоп%l%scania%4%(96-04)%' THEN 0
                                    WHEN `products`.`ArtNumber` LIKE 'стоп%l%scania%4%(96-04)%' THEN 1
                                    WHEN `products`.`Brand` LIKE 'стоп%l%scania%4%(96-04)%' THEN 2
                                    WHEN `product_texts`.`Title` LIKE 'стоп%l%scania%4%(96-04)%' THEN 3
                                    WHEN `product_texts`.`Title` LIKE '% стоп%l%scania%4%(96-04)%' THEN 4
                                    ELSE 5
                                END
                            ) AS CountTable
# [25-Jan-2023 15:36:49] /unicat/root/nRqioDzp/bg/ajax/products/form/9162.html?_=1674653883645 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
                `products`.*,
                `product_texts`.*,
                GROUP_CONCAT(`GroupID` SEPARATOR ',') AS `Groups`
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
                LEFT JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
            WHERE
                `products`.`ID` = 9162 AND
                `product_texts`.`Language` = 'bg'
            LIMIT 1

SELECT `ImgValues` FROM `params` WHERE `Code` = 'brand' LIMIT 1

SELECT
                `groups`.`ID`,
                `groups`.`ParentID`,
                `group_texts`.`Title`,
                `group_texts`.`MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg'
            ORDER BY
                `groups`.`ParentID` ASC,
                `groups`.`PostDate` ASC

SELECT
                `groups`.`ID`,
                `groups`.`ParentID`,
                `group_texts`.`Title`,
                `group_texts`.`MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg'
            ORDER BY
                `groups`.`ParentID` ASC,
                `groups`.`PostDate` ASC

SELECT
                    `GroupID`
                FROM
                    `product_groups`
                WHERE
                    `ProductID` = 9162

SELECT
                `MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg' AND
                `groups`.`ID` IN (
                    WITH RECURSIVE `cte` (`ParentID`) AS (
                        SELECT `ID` FROM `groups` WHERE `ID` = 892
                        UNION ALL
                        SELECT `groups`.`ParentID` FROM `groups` INNER JOIN `cte` ON `groups`.`ID` = `cte`.`ParentID`
                    )
                    SELECT `cte`.`ParentID` FROM `cte`
                )

SELECT
                    `param_texts`.`ParamID`,
                    IF(
                        `param_texts`.`Metric` = '',
                        `param_texts`.`Title`,
                        CONCAT_WS(' ', `param_texts`.`Title`, CONCAT('[', `param_texts`.`Metric`, ']'))
                    ) AS `Param`
                FROM
                    `params`
                    INNER JOIN `param_texts` ON `params`.`ID` = `param_texts`.`ParamID`
                WHERE
                    `param_texts`.`Language` = 'bg'
                ORDER BY
                    `param_texts`.`Title` ASC

SELECT
                    `param_texts`.`ParamID`,
                    IF(
                        `param_texts`.`Metric` = '',
                        `param_texts`.`Title`,
                        CONCAT_WS(' ', `param_texts`.`Title`, CONCAT('[', `param_texts`.`Metric`, ']'))
                    ) AS `Param`,
                    `ParamValue`
                FROM
                    `product_params`
                    INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                    INNER JOIN `param_texts` ON `product_params`.`ParamID` = `param_texts`.`ParamID`
                WHERE
                    `product_params`.`ProductID` = 9162 AND
                    `param_texts`.`Language` = 'bg'
                ORDER BY
                    `params`.`PostDate` DESC
# [25-Jan-2023 15:37:19] /unicat/root/nRqioDzp/bg/params/list.html 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
               *
            FROM
                `params`
                INNER JOIN `param_texts` ON `params`.`ID` = `param_texts`.`ParamID`
            WHERE
                `Language` = 'bg'
         ORDER BY `params`.`LastUpdate` ASC
# [25-Jan-2023 15:38:00] /unicat/root/nRqioDzp/bg/ajax/params/form/41.html?_=1674653954620 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
                *
            FROM
                `params`
                INNER JOIN `param_texts` ON `params`.`ID` = `param_texts`.`ParamID`
            WHERE
                `params`.`ID` = 41 AND
                `param_texts`.`Language` = 'bg'
            LIMIT 1
# [25-Jan-2023 15:38:26] /unicat/root/bg/products/светлини-за-товарни/задни-светлини.html 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
                    `GT1`.`GroupID`
                FROM
                    `group_texts` AS `GT1`
                    INNER JOIN `groups` ON `groups`.`ID` = `GT1`.`GroupID`
                    INNER JOIN `group_texts` AS `GT2` ON `groups`.`ParentID` = `GT2`.`GroupID`
                WHERE
                    `GT1`.`URLLabel` = 'задни-светлини' AND
                    `GT2`.`URLLabel` = 'светлини-за-товарни' AND
                    `GT1`.`Language` = 'bg' AND
                    `GT2`.`Language` = 'bg'
                LIMIT 1

SELECT
                `G1`.`ID`,
                `GT1`.`MenuLabel`,
                `GT1`.`Title`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                `GT1`.`URLLabel`,
                (SELECT `ID` FROM `groups` WHERE `ParentID` = `G1`.`ID` LIMIT 1) AS `ChildID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `GT1`.`Language` = 'bg' AND
                `G1`.`ID` IN (
                    WITH RECURSIVE `cte` (`ParentID`) AS (
                        SELECT `ID` FROM `groups` WHERE `ID` = 892
                        UNION ALL
                        SELECT `groups`.`ParentID` FROM `groups` INNER JOIN `cte` ON `groups`.`ID` = `cte`.`ParentID`
                    )
                    SELECT `cte`.`ParentID` FROM `cte`
                )
            GROUP BY
                `G1`.`ID`

SELECT
                `G1`.`ID`,
                `G1`.`ParentID`,
                `GT1`.`MenuLabel`,
                `GT1`.`URLLabel`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                (SELECT `ID` FROM `groups` WHERE `ParentID` = `G1`.`ID` LIMIT 1) AS `ChildID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `G1`.`Visible` = 1 AND
                `GT1`.`Language` = 'bg'

            GROUP BY
                `G1`.`ID`
            ORDER BY
                `G1`.`ParentID` ASC,
                `G1`.`PostDate` ASC

SELECT
                `params`.`ID`
            FROM
                `product_groups`
                INNER JOIN `product_params` ON `product_groups`.`ProductID` = `product_params`.`ProductID`
                INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
            WHERE
                `product_groups`.`GroupID` = 892 AND
                `params`.`FilterType` > 0 AND
                `params`.`Required` = 1
            GROUP BY
                `params`.`ID`
            ORDER BY
                `params`.`PostDate` ASC

SELECT
               `products`.`ID`,
               `products`.`UploadID`,
               `products`.`RefNumber`,
               `products`.`RefID`,
               `products`.`Brand`,
               `products`.`Gallery`,
               `product_texts`.`Title`,
               `product_texts`.`URLLabel`,
               (
                    SELECT
                        GROUP_CONCAT(DISTINCT CONCAT_WS('][', `product_params`.`ParamID`, `product_params`.`ParamValue`) SEPARATOR '|') AS `Params`
                    FROM
                        `product_params`
                        INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                    WHERE
                        `product_params`.`ProductID` = `products`.`ID` AND
                        `params`.`FilterType` IN (1,2,3) AND
                        `params`.`Code` != 'brand'
                    GROUP BY
                        `product_params`.`ProductID`
               ) AS `Params`,
               (
                    SELECT
                        GROUP_CONCAT(DISTINCT CONCAT_WS('-', `product_params`.`ParamID`, `product_params`.`ParamValue`) SEPARATOR '|') AS `Params`
                    FROM
                        `product_params`
                        INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                    WHERE
                        `product_params`.`ProductID` = `products`.`ID` AND
                        `params`.`FilterType` IN (4,5) AND
                        `params`.`Code` != 'brand'
                    GROUP BY
                        `product_params`.`ProductID`
               ) AS `Ranges`
            FROM
                `products`
                INNER JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
                INNER JOIN `groups` ON `product_groups`.`GroupID` = `groups`.`ID`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
                
            WHERE
                `product_groups`.`GroupID` = 892 AND
                `product_texts`.`Language` = 'bg' AND
                `products`.`Visible` = 1 AND
                `groups`.`Visible` = 1
            GROUP BY
                `products`.`ID`
            ORDER BY
                `products`.`PostDate` ASC

SET SESSION group_concat_max_len = 10240

SELECT
                `param_texts`.`Title`,
                `param_texts`.`Metric`,
                `params`.`ID`,
                `params`.`UploadID`,
                `params`.`FilterType`,
                `params`.`ImgValues`,
                `params`.`Prefix`,
                `params`.`Code`,
                GROUP_CONCAT(DISTINCT `PPV`.`ParamValue` SEPARATOR '][') AS `Values`
            FROM
                `products`
                INNER JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
                INNER JOIN `product_params` AS `PPV` ON `products`.`ID` = `PPV`.`ProductID`
                INNER JOIN `params` ON `params`.`ID` = `PPV`.`ParamID`
                INNER JOIN `param_texts` ON `params`.`ID` = `param_texts`.`ParamID`
                
            WHERE
                `product_groups`.`GroupID` = 892 AND
                `params`.`FilterType` > 0 AND
                `params`.`Required` = 0
            GROUP BY
                `params`.`ID`
            ORDER BY
                `params`.`PostDate` ASC
# [25-Jan-2023 15:38:26] /unicat/root/bg/ajax/users/session.html?_=1674653980461 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1
# [25-Jan-2023 15:38:26] /unicat/root/bg/ajax/prices.html?_=1674653980528 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT `Token` FROM `token` WHERE `Expires` > CURDATE()

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-002l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-002r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '1060-was' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '1062-was' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-002al' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-002l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-002ar' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '206152-sampa' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '206153-sampa' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-028' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-027' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-026' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-025' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-023a-24' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-63-024l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-63-024r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-63-002l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-63-002r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-57-003l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-57-003r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-001l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-001r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-001l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-001r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-032ahl' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-032ahr-24' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-019l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-019r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-007l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-007r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-003l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-003r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'm611437' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'm611436' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '6606872' AND `Visible` = 1 LIMIT 1
# [25-Jan-2023 15:38:32] /unicat/root/bg/ajax/prices.html?_=1674653986200 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT `Token` FROM `token` WHERE `Expires` > CURDATE()

SELECT `RefNumber` FROM `products` WHERE `RefID` = '0350ll' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '0350lq1l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-003l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-009l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'd12340-vignal' AND `Visible` = 1 LIMIT 1
# [25-Jan-2023 15:39:28] /unicat/root/bg/products/892/td0252002l.html 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
               `products`.*,
               `product_texts`.*
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
                INNER JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
            WHERE
                `product_texts`.`URLLabel` = 'td0252002l' AND
                `product_texts`.`Language` = 'bg' AND
                `product_groups`.`GroupID` = 892
            LIMIT 1

SELECT
                `G1`.`ID`,
                `GT1`.`MenuLabel`,
                `GT1`.`Title`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                `GT1`.`URLLabel`,
                (SELECT `ID` FROM `groups` WHERE `ParentID` = `G1`.`ID` LIMIT 1) AS `ChildID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `GT1`.`Language` = 'bg' AND
                `G1`.`ID` IN (
                    WITH RECURSIVE `cte` (`ParentID`) AS (
                        SELECT `ID` FROM `groups` WHERE `ID` = 892
                        UNION ALL
                        SELECT `groups`.`ParentID` FROM `groups` INNER JOIN `cte` ON `groups`.`ID` = `cte`.`ParentID`
                    )
                    SELECT `cte`.`ParentID` FROM `cte`
                )
            GROUP BY
                `G1`.`ID`

SELECT
                `G1`.`ID`,
                `G1`.`ParentID`,
                `GT1`.`MenuLabel`,
                `GT1`.`URLLabel`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                (SELECT `ID` FROM `groups` WHERE `ParentID` = `G1`.`ID` LIMIT 1) AS `ChildID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `G1`.`Visible` = 1 AND
                `GT1`.`Language` = 'bg'

            GROUP BY
                `G1`.`ID`
            ORDER BY
                `G1`.`ParentID` ASC,
                `G1`.`PostDate` ASC

SELECT
                `params`.`Code`,
                `params`.`UploadID`,
                `params`.`ImgValues`,
                `product_params`.`ParamID`,
                `param_texts`.`Title`,
                `param_texts`.`Metric`,
                `params`.`Prefix`,
                GROUP_CONCAT(`ParamValue` separator '<br />') AS `Values`
            FROM
                `product_params`
                INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                INNER JOIN `param_texts` ON `product_params`.`ParamID` = `param_texts`.`ParamID`
            WHERE
                `product_params`.`ProductID` = 9162 AND
                `param_texts`.`Language` = 'bg'
            GROUP BY
                `product_params`.`ParamID`
            ORDER BY
                `params`.`PostDate` DESC
# [25-Jan-2023 15:39:28] /unicat/root/bg/ajax/users/session.html?_=1674654042297 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1
# [25-Jan-2023 15:39:28] /unicat/root/bg/ajax/prices.html?_=1674654042339 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT `Token` FROM `token` WHERE `Expires` > CURDATE()

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-002l' AND `Visible` = 1 LIMIT 1
# [25-Jan-2023 15:39:44] /unicat/root/nRqioDzp/bg/products/list.html 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
               *
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `Language` = 'bg'
         ORDER BY `products`.`LastUpdate` ASC LIMIT 0, 100

SELECT COUNT(*) AS NumRows FROM (
            SELECT
               *
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `Language` = 'bg'
         ORDER BY `products`.`LastUpdate` ASC) AS CountTable
# [25-Jan-2023 15:39:46] /unicat/root/nRqioDzp/bg/products/list.html?keyword=Стоп L SCANIA 4 (96-04)  167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
               *
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `Language` = 'bg'
         AND (
                                `products`.`RefID` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`RefNumber` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`ArtNumber` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`Brand` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `product_texts`.`Title` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `product_texts`.`Content` LIKE '%стоп%l%scania%4%(96-04)%'
                            )
                        
                                ORDER BY CASE
                                    WHEN `products`.`RefNumber` LIKE 'стоп%l%scania%4%(96-04)%' THEN 0
                                    WHEN `products`.`ArtNumber` LIKE 'стоп%l%scania%4%(96-04)%' THEN 1
                                    WHEN `products`.`Brand` LIKE 'стоп%l%scania%4%(96-04)%' THEN 2
                                    WHEN `product_texts`.`Title` LIKE 'стоп%l%scania%4%(96-04)%' THEN 3
                                    WHEN `product_texts`.`Title` LIKE '% стоп%l%scania%4%(96-04)%' THEN 4
                                    ELSE 5
                                END
                             LIMIT 0, 100

SELECT COUNT(*) AS NumRows FROM (
            SELECT
               *
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `Language` = 'bg'
         AND (
                                `products`.`RefID` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`RefNumber` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`ArtNumber` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`Brand` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `product_texts`.`Title` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `product_texts`.`Content` LIKE '%стоп%l%scania%4%(96-04)%'
                            )
                        
                                ORDER BY CASE
                                    WHEN `products`.`RefNumber` LIKE 'стоп%l%scania%4%(96-04)%' THEN 0
                                    WHEN `products`.`ArtNumber` LIKE 'стоп%l%scania%4%(96-04)%' THEN 1
                                    WHEN `products`.`Brand` LIKE 'стоп%l%scania%4%(96-04)%' THEN 2
                                    WHEN `product_texts`.`Title` LIKE 'стоп%l%scania%4%(96-04)%' THEN 3
                                    WHEN `product_texts`.`Title` LIKE '% стоп%l%scania%4%(96-04)%' THEN 4
                                    ELSE 5
                                END
                            ) AS CountTable
# [25-Jan-2023 15:39:49] /unicat/root/nRqioDzp/bg/ajax/products/form/9162.html?_=1674654062953 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
                `products`.*,
                `product_texts`.*,
                GROUP_CONCAT(`GroupID` SEPARATOR ',') AS `Groups`
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
                LEFT JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
            WHERE
                `products`.`ID` = 9162 AND
                `product_texts`.`Language` = 'bg'
            LIMIT 1

SELECT `ImgValues` FROM `params` WHERE `Code` = 'brand' LIMIT 1

SELECT
                `groups`.`ID`,
                `groups`.`ParentID`,
                `group_texts`.`Title`,
                `group_texts`.`MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg'
            ORDER BY
                `groups`.`ParentID` ASC,
                `groups`.`PostDate` ASC

SELECT
                `groups`.`ID`,
                `groups`.`ParentID`,
                `group_texts`.`Title`,
                `group_texts`.`MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg'
            ORDER BY
                `groups`.`ParentID` ASC,
                `groups`.`PostDate` ASC

SELECT
                    `GroupID`
                FROM
                    `product_groups`
                WHERE
                    `ProductID` = 9162

SELECT
                `MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg' AND
                `groups`.`ID` IN (
                    WITH RECURSIVE `cte` (`ParentID`) AS (
                        SELECT `ID` FROM `groups` WHERE `ID` = 892
                        UNION ALL
                        SELECT `groups`.`ParentID` FROM `groups` INNER JOIN `cte` ON `groups`.`ID` = `cte`.`ParentID`
                    )
                    SELECT `cte`.`ParentID` FROM `cte`
                )

SELECT
                    `param_texts`.`ParamID`,
                    IF(
                        `param_texts`.`Metric` = '',
                        `param_texts`.`Title`,
                        CONCAT_WS(' ', `param_texts`.`Title`, CONCAT('[', `param_texts`.`Metric`, ']'))
                    ) AS `Param`
                FROM
                    `params`
                    INNER JOIN `param_texts` ON `params`.`ID` = `param_texts`.`ParamID`
                WHERE
                    `param_texts`.`Language` = 'bg'
                ORDER BY
                    `param_texts`.`Title` ASC

SELECT
                    `param_texts`.`ParamID`,
                    IF(
                        `param_texts`.`Metric` = '',
                        `param_texts`.`Title`,
                        CONCAT_WS(' ', `param_texts`.`Title`, CONCAT('[', `param_texts`.`Metric`, ']'))
                    ) AS `Param`,
                    `ParamValue`
                FROM
                    `product_params`
                    INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                    INNER JOIN `param_texts` ON `product_params`.`ParamID` = `param_texts`.`ParamID`
                WHERE
                    `product_params`.`ProductID` = 9162 AND
                    `param_texts`.`Language` = 'bg'
                ORDER BY
                    `params`.`PostDate` DESC
# [25-Jan-2023 15:40:12] /unicat/root/nRqioDzp/bg/ajax/products/update/9162.html?_=1674654086626 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
                `ID`
            FROM
                `products`
            WHERE
                `RefID` = 'td02-52-002l'
         AND `ID` != 9162 LIMIT 1

SELECT * FROM `products` LIMIT 1

SHOW COLUMNS FROM `products`

UPDATE `products` SET `ID` = '9162', `PostDate` = '2236-05-04', `LastUpdate` = '2023-01-25 15:40:12', `UploadID` = '2022/07/19/8229181490', `PromoStart` = NULL, `PromoEnd` = NULL, `Timer` = 0, `RefNumber` = 'TD02-52-002L', `RefID` = 'td02-52-002l', `ArtNumber` = 'TD02-52-002L', `Brand` = 'ОБОРУДВАНЕ КАБИНА И РЕМАРКЕ', `Gallery` = '["td02-52-002l_001.jpg","td02-52-002l_002.jpg"]', `Selected` = 0, `Visible` = 1 WHERE `ID` = '9162'

SELECT * FROM `product_texts` LIMIT 1

SHOW COLUMNS FROM `product_texts`

UPDATE `product_texts` SET `ProductID` = '9162', `Language` = 'bg', `Title` = 'Стоп L SCANIA 4 (96-04)', `URLLabel` = 'td0252002l', `Content` = 'Стоп L SCANIA 4 (96-04)' WHERE `ProductID` = '9162' AND `Language` = 'bg'

DELETE FROM `product_groups` WHERE `ProductID` = '9162'

INSERT INTO `product_groups` (`ProductID`, `GroupID`) VALUES 
	('9162', '892');

DELETE FROM `product_params` WHERE `ProductID` = '9162'

INSERT INTO `product_params` (`ProductID`, `ParamID`, `ParamValue`) VALUES 
	('9162', '58', 'БЕЗ БУКСА'),
	('9162', '60', 'TD02-51-003S'),
	('9162', '41', 'КРУШКА'),
	('9162', '42', 'L - ЛЯВО'),
	('9162', '43', 'TD02-52-002R'),
	('9162', '11', 'TD02-52-002L'),
	('9162', '2', 'ОБОРУДВАНЕ КАБИНА И РЕМАРКЕ'),
	('9162', '41', 'led');
# [25-Jan-2023 15:40:13] /unicat/root/nRqioDzp/bg/products/list.html?keyword=Стоп L SCANIA 4 (96-04)  167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
               *
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `Language` = 'bg'
         AND (
                                `products`.`RefID` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`RefNumber` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`ArtNumber` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`Brand` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `product_texts`.`Title` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `product_texts`.`Content` LIKE '%стоп%l%scania%4%(96-04)%'
                            )
                        
                                ORDER BY CASE
                                    WHEN `products`.`RefNumber` LIKE 'стоп%l%scania%4%(96-04)%' THEN 0
                                    WHEN `products`.`ArtNumber` LIKE 'стоп%l%scania%4%(96-04)%' THEN 1
                                    WHEN `products`.`Brand` LIKE 'стоп%l%scania%4%(96-04)%' THEN 2
                                    WHEN `product_texts`.`Title` LIKE 'стоп%l%scania%4%(96-04)%' THEN 3
                                    WHEN `product_texts`.`Title` LIKE '% стоп%l%scania%4%(96-04)%' THEN 4
                                    ELSE 5
                                END
                             LIMIT 0, 100

SELECT COUNT(*) AS NumRows FROM (
            SELECT
               *
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
            WHERE
                `Language` = 'bg'
         AND (
                                `products`.`RefID` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`RefNumber` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`ArtNumber` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `products`.`Brand` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `product_texts`.`Title` LIKE '%стоп%l%scania%4%(96-04)%' OR
                                `product_texts`.`Content` LIKE '%стоп%l%scania%4%(96-04)%'
                            )
                        
                                ORDER BY CASE
                                    WHEN `products`.`RefNumber` LIKE 'стоп%l%scania%4%(96-04)%' THEN 0
                                    WHEN `products`.`ArtNumber` LIKE 'стоп%l%scania%4%(96-04)%' THEN 1
                                    WHEN `products`.`Brand` LIKE 'стоп%l%scania%4%(96-04)%' THEN 2
                                    WHEN `product_texts`.`Title` LIKE 'стоп%l%scania%4%(96-04)%' THEN 3
                                    WHEN `product_texts`.`Title` LIKE '% стоп%l%scania%4%(96-04)%' THEN 4
                                    ELSE 5
                                END
                            ) AS CountTable
# [25-Jan-2023 15:40:17] /unicat/root/bg/products/светлини-за-товарни/задни-светлини.html 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
                    `GT1`.`GroupID`
                FROM
                    `group_texts` AS `GT1`
                    INNER JOIN `groups` ON `groups`.`ID` = `GT1`.`GroupID`
                    INNER JOIN `group_texts` AS `GT2` ON `groups`.`ParentID` = `GT2`.`GroupID`
                WHERE
                    `GT1`.`URLLabel` = 'задни-светлини' AND
                    `GT2`.`URLLabel` = 'светлини-за-товарни' AND
                    `GT1`.`Language` = 'bg' AND
                    `GT2`.`Language` = 'bg'
                LIMIT 1

SELECT
                `G1`.`ID`,
                `GT1`.`MenuLabel`,
                `GT1`.`Title`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                `GT1`.`URLLabel`,
                (SELECT `ID` FROM `groups` WHERE `ParentID` = `G1`.`ID` LIMIT 1) AS `ChildID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `GT1`.`Language` = 'bg' AND
                `G1`.`ID` IN (
                    WITH RECURSIVE `cte` (`ParentID`) AS (
                        SELECT `ID` FROM `groups` WHERE `ID` = 892
                        UNION ALL
                        SELECT `groups`.`ParentID` FROM `groups` INNER JOIN `cte` ON `groups`.`ID` = `cte`.`ParentID`
                    )
                    SELECT `cte`.`ParentID` FROM `cte`
                )
            GROUP BY
                `G1`.`ID`

SELECT
                `G1`.`ID`,
                `G1`.`ParentID`,
                `GT1`.`MenuLabel`,
                `GT1`.`URLLabel`,
                `GT2`.`URLLabel` AS `ParentURLLabel`,
                (SELECT `ID` FROM `groups` WHERE `ParentID` = `G1`.`ID` LIMIT 1) AS `ChildID`
            FROM
                `groups` AS `G1`
                INNER JOIN `group_texts` AS `GT1` ON `G1`.`ID` = `GT1`.`GroupID`
                LEFT JOIN `group_texts` AS `GT2` ON `G1`.`ParentID` = `GT2`.`GroupID` AND `GT2`.`Language` = 'bg'
                LEFT JOIN `groups` AS `G2` ON `G1`.`ID` = `G2`.`ParentID`
            WHERE
                `G1`.`Visible` = 1 AND
                `GT1`.`Language` = 'bg'

            GROUP BY
                `G1`.`ID`
            ORDER BY
                `G1`.`ParentID` ASC,
                `G1`.`PostDate` ASC

SELECT
                `params`.`ID`
            FROM
                `product_groups`
                INNER JOIN `product_params` ON `product_groups`.`ProductID` = `product_params`.`ProductID`
                INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
            WHERE
                `product_groups`.`GroupID` = 892 AND
                `params`.`FilterType` > 0 AND
                `params`.`Required` = 1
            GROUP BY
                `params`.`ID`
            ORDER BY
                `params`.`PostDate` ASC

SELECT
               `products`.`ID`,
               `products`.`UploadID`,
               `products`.`RefNumber`,
               `products`.`RefID`,
               `products`.`Brand`,
               `products`.`Gallery`,
               `product_texts`.`Title`,
               `product_texts`.`URLLabel`,
               (
                    SELECT
                        GROUP_CONCAT(DISTINCT CONCAT_WS('][', `product_params`.`ParamID`, `product_params`.`ParamValue`) SEPARATOR '|') AS `Params`
                    FROM
                        `product_params`
                        INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                    WHERE
                        `product_params`.`ProductID` = `products`.`ID` AND
                        `params`.`FilterType` IN (1,2,3) AND
                        `params`.`Code` != 'brand'
                    GROUP BY
                        `product_params`.`ProductID`
               ) AS `Params`,
               (
                    SELECT
                        GROUP_CONCAT(DISTINCT CONCAT_WS('-', `product_params`.`ParamID`, `product_params`.`ParamValue`) SEPARATOR '|') AS `Params`
                    FROM
                        `product_params`
                        INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                    WHERE
                        `product_params`.`ProductID` = `products`.`ID` AND
                        `params`.`FilterType` IN (4,5) AND
                        `params`.`Code` != 'brand'
                    GROUP BY
                        `product_params`.`ProductID`
               ) AS `Ranges`
            FROM
                `products`
                INNER JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
                INNER JOIN `groups` ON `product_groups`.`GroupID` = `groups`.`ID`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
                
            WHERE
                `product_groups`.`GroupID` = 892 AND
                `product_texts`.`Language` = 'bg' AND
                `products`.`Visible` = 1 AND
                `groups`.`Visible` = 1
            GROUP BY
                `products`.`ID`
            ORDER BY
                `products`.`PostDate` ASC

SET SESSION group_concat_max_len = 10240

SELECT
                `param_texts`.`Title`,
                `param_texts`.`Metric`,
                `params`.`ID`,
                `params`.`UploadID`,
                `params`.`FilterType`,
                `params`.`ImgValues`,
                `params`.`Prefix`,
                `params`.`Code`,
                GROUP_CONCAT(DISTINCT `PPV`.`ParamValue` SEPARATOR '][') AS `Values`
            FROM
                `products`
                INNER JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
                INNER JOIN `product_params` AS `PPV` ON `products`.`ID` = `PPV`.`ProductID`
                INNER JOIN `params` ON `params`.`ID` = `PPV`.`ParamID`
                INNER JOIN `param_texts` ON `params`.`ID` = `param_texts`.`ParamID`
                
            WHERE
                `product_groups`.`GroupID` = 892 AND
                `params`.`FilterType` > 0 AND
                `params`.`Required` = 0
            GROUP BY
                `params`.`ID`
            ORDER BY
                `params`.`PostDate` ASC
# [25-Jan-2023 15:40:17] /unicat/root/bg/ajax/users/session.html?_=1674654091681 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1
# [25-Jan-2023 15:40:18] /unicat/root/bg/ajax/prices.html?_=1674654091739 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT `Token` FROM `token` WHERE `Expires` > CURDATE()

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-002l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-002r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '1060-was' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '1062-was' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-002al' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-002l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-002ar' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '206152-sampa' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '206153-sampa' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-028' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-027' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-026' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-025' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td03-68-023a-24' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-63-024l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-63-024r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-63-002l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-63-002r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-57-003l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-57-003r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-001l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-52-001r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-001l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-51-001r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-032ahl' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-032ahr-24' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-019l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-019r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-007l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-007r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-003l' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'td02-50-003r' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'm611437' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = 'm611436' AND `Visible` = 1 LIMIT 1

SELECT `RefNumber` FROM `products` WHERE `RefID` = '6606872' AND `Visible` = 1 LIMIT 1
# [25-Jan-2023 15:40:49] /unicat/root/nRqioDzp/bg/ajax/products/form/9162.html?_=1674654123199 167.99.142.201

set names utf8

SELECT
                            `UserKey`
                        FROM
                            `users`
                        WHERE
                            `ID` = 1462881436 AND
                            RIGHT(`UserKey`, 1) = 1
                        LIMIT 1

SELECT
                `products`.*,
                `product_texts`.*,
                GROUP_CONCAT(`GroupID` SEPARATOR ',') AS `Groups`
            FROM
                `products`
                INNER JOIN `product_texts` ON `products`.`ID` = `product_texts`.`ProductID`
                LEFT JOIN `product_groups` ON `products`.`ID` = `product_groups`.`ProductID`
            WHERE
                `products`.`ID` = 9162 AND
                `product_texts`.`Language` = 'bg'
            LIMIT 1

SELECT `ImgValues` FROM `params` WHERE `Code` = 'brand' LIMIT 1

SELECT
                `groups`.`ID`,
                `groups`.`ParentID`,
                `group_texts`.`Title`,
                `group_texts`.`MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg'
            ORDER BY
                `groups`.`ParentID` ASC,
                `groups`.`PostDate` ASC

SELECT
                `groups`.`ID`,
                `groups`.`ParentID`,
                `group_texts`.`Title`,
                `group_texts`.`MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg'
            ORDER BY
                `groups`.`ParentID` ASC,
                `groups`.`PostDate` ASC

SELECT
                    `GroupID`
                FROM
                    `product_groups`
                WHERE
                    `ProductID` = 9162

SELECT
                `MenuLabel`
            FROM
                `groups`
                INNER JOIN `group_texts` ON `groups`.`ID` = `group_texts`.`GroupID`
            WHERE
                `group_texts`.`Language` = 'bg' AND
                `groups`.`ID` IN (
                    WITH RECURSIVE `cte` (`ParentID`) AS (
                        SELECT `ID` FROM `groups` WHERE `ID` = 892
                        UNION ALL
                        SELECT `groups`.`ParentID` FROM `groups` INNER JOIN `cte` ON `groups`.`ID` = `cte`.`ParentID`
                    )
                    SELECT `cte`.`ParentID` FROM `cte`
                )

SELECT
                    `param_texts`.`ParamID`,
                    IF(
                        `param_texts`.`Metric` = '',
                        `param_texts`.`Title`,
                        CONCAT_WS(' ', `param_texts`.`Title`, CONCAT('[', `param_texts`.`Metric`, ']'))
                    ) AS `Param`
                FROM
                    `params`
                    INNER JOIN `param_texts` ON `params`.`ID` = `param_texts`.`ParamID`
                WHERE
                    `param_texts`.`Language` = 'bg'
                ORDER BY
                    `param_texts`.`Title` ASC

SELECT
                    `param_texts`.`ParamID`,
                    IF(
                        `param_texts`.`Metric` = '',
                        `param_texts`.`Title`,
                        CONCAT_WS(' ', `param_texts`.`Title`, CONCAT('[', `param_texts`.`Metric`, ']'))
                    ) AS `Param`,
                    `ParamValue`
                FROM
                    `product_params`
                    INNER JOIN `params` ON `params`.`ID` = `product_params`.`ParamID`
                    INNER JOIN `param_texts` ON `product_params`.`ParamID` = `param_texts`.`ParamID`
                WHERE
                    `product_params`.`ProductID` = 9162 AND
                    `param_texts`.`Language` = 'bg'
                ORDER BY
                    `params`.`PostDate` DESC
