# [21-Jan-2025 06:50:33] /finance/root/bg/invoices.html 167.99.142.201

set names utf8

SELECT * FROM `invoices` AS `Inv` WHERE `Inv`.`Type` > 0 ORDER BY `Inv`.`PostDate` DESC, `Inv`.`ID` DESC
# [21-Jan-2025 06:51:44] /finance/root/bg/ajax/invoices/form/clone/2392.html?pid=2392&_=1737435104490 167.99.142.201

set names utf8

SELECT
                *
            FROM
                `invoices`
            WHERE
                `ID` = 2392
            LIMIT 1

SELECT
                `ID`,
                `Data`
            FROM
                `clients`
            WHERE
         `Type` = 0 AND 
                    `Top` = 1
                ORDER BY
                    `PostDate`
                LIMIT 20

SELECT
                `ID`,
                `Data`
            FROM
                `clients`
            WHERE
         `Type` = 1 AND 
                    `Top` = 1
                ORDER BY
                    `PostDate`
                LIMIT 20
# [21-Jan-2025 06:51:53] /finance/root/bg/ajax/invoices/insert.html?_=1737435113794 167.99.142.201

set names utf8

SELECT
                *
            FROM
                `clients`
            WHERE
                `ID` = 75 AND
                `Visible` = 1
            LIMIT 1

SELECT
                *
            FROM
                `clients`
            WHERE
                `ID` = 1 AND
                `Visible` = 1
            LIMIT 1

SELECT MAX(`ID`) + 1 FROM `invoices` WHERE `Type` > 0 AND `ID` < 1000000000

SELECT * FROM `invoices` LIMIT 1

SHOW COLUMNS FROM `invoices`

INSERT INTO `invoices` SET `ID` = '2408', `Language` = 'bg', `PostDate` = '2025-01-21', `LastUpdate` = '2025-01-21 06:51:53', `Type` = '1', `ParentID` = 0, `Data` = 'mmJfYS221ys81Dz-ozvO6BlRGQBk49OZtvl4qAoHwDGelNtiG0aAG7qBD2q7or_xvae4QL4oFfTHUi4WRdhr4lnQQd9GV19zOfAgl-sLRwB5iHBXlcz3fEKc793ciDYdK-gF_O2KnpoLvheqTMbFki3enBR01WYSXyeGDU9kfCO22X2xOGTyHLqamGyr5nfZ0lXoV-AUIMLMM6LRz8QKe2cQyqc8e3KrfYKCGb3Al_ht6bdU69gyo-MhPE-L1W2AfP5j82j21cwhSTjlX5v5tre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-Jan-2025 06:51:53] /finance/root/bg/invoices.html 167.99.142.201

set names utf8

SELECT * FROM `invoices` AS `Inv` WHERE `Inv`.`Type` > 0 ORDER BY `Inv`.`PostDate` DESC, `Inv`.`ID` DESC
# [21-Jan-2025 06:51:56] /finance/root/bg/invoices/2408.html 167.99.142.201

set names utf8

SELECT
                `Inv`.*,
                `Original`.`PostDate` AS `OriginalPostDate`
            FROM
                `invoices` AS `Inv`
                LEFT JOIN `invoices` AS `Original` ON `Inv`.`ParentID` = `Original`.`ID`
            WHERE
                `Inv`.`ID` = 2408
            LIMIT 1

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Label` IN ('Jan') AND
                `Language` = 'bg'
             ORDER BY
                `labels`.`Label` ASC
