# [03-Jan-2025 15:37:58] /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
# [03-Jan-2025 15:38:10] /finance/root/bg/ajax/invoices/form/clone/2383.html?pid=2383&_=1735911489685 167.99.142.201

set names utf8

SELECT
                *
            FROM
                `invoices`
            WHERE
                `ID` = 2383
            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
# [03-Jan-2025 15:38:31] /finance/root/bg/ajax/invoices/insert.html?_=1735911510889 167.99.142.201

set names utf8

SELECT
                *
            FROM
                `clients`
            WHERE
                `ID` = 68 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` = '2403', `Language` = 'bg', `PostDate` = '2025-01-03', `LastUpdate` = '2025-01-03 15:38:31', `Type` = '1', `ParentID` = 0, `Data` = '2SaRVCt1WfLHFksdm1LSU_M-Ct53P2C65v8R66ER8d7LPjG0YwE9sSI6T8jT_w_sNWTypZQHkWxs-nm98Ox15h6eyn75gzZYcV36MNzbAmNqqlmY2mXVcyded1HSpRWXHeMUzuUoGqA2KfuoiSE2VTb_NgZ2lDomaun5f7tG9-GzTt1M91hiRrmyo0vC8v6F18enamNhHhPI5gAU0o2NRegUtWqYt-iNT8YDviiUkN8RPZOxbr6XOhhXUqoL2nsRAJ83Xy-z9KY7-fFx_olECsVxg3Dabmky6jLSUQVomsd63aztIFAI4ETXevRre0N9QFuM9soVirm-2hfSX2mkmwKuYdKmR2goYQeOlXaZb4unPxtmPCSBJvGbuvDvnQIU9mIYoKrw1J6_P9WSuk-3gAQ1vehco_mbSvXyOe-mA2gOGfxvZ1aItsgNL9TnKwOSwzEm6nyTrzVxairBCj_jLN7jGHfdjGOLIRt3MQT4Hb1vuC2uV4OSJjPOgI0ZRX_2LLqljJ3tcBdr3ZtfOyWSZq9HlK3Sc6wNXGu6Cm_moV4yj07IFSEEflvA91vRywRr3oYmkY7ik65Cc2Kj6_yqrdHZgtCE7ULhnbLnqyWB_mrr_tpnDc_NXSEyO050n_StnlU0mVnaxxrxD-1ilMtUn3NoXuTbYCt8CDD5jbsU0RYMNTRwQSBnRD37UfhKGbAC1myJyZ-0UqZsQBxfDpMMrvCdzgyYcxYKQt_qrN0FxUAt1TD7WrGbujF1iQWHJdv3UVdXrQCrkT2GJv9WjMQjMpZhGRmUxELGPS2Teu2iN5UQrKXjuvX50g-tG0qN0RazTzBGKODM88rQqupditRrQJSt1E0qoWivY1FFuaKQiZvy_cP44cwOQB--RELDNJZt1YuIGamPknzgDMcuHMVFCCFKjtHndkF9PSQkb5mtj5Z9fBRa1m2CHCo1giZS6SWD4Qn8ftA7lW1mbeG5BgxC3kLK8Hw-eck1AAMly-2C0Gc', `SearchKey` = 'wofCscK8w4DCtMK6wqCqMKDwqTDnsKrw5vDn8KdwwofCpMOAw4DCtMwofCpMOIwrDg8OgwqCocKDwqTCwrvCoMK6w57CpsKewqXDwofCscK0wrDgcOQwqCqsKDwqTDosKrw5jCucKdwqfChMKhwqrCvMOXwwofCpMK4w4DCt8OgwqCpMKDwqTDjsKrw5nDj8KhwwofCpMOWwrDgMwrHDhcK2w5jCp8ODwrbDqsK1worDwofCpMOWwrDgMwofCpM'
# [03-Jan-2025 15:38:31] /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
# [03-Jan-2025 15:38:34] /finance/root/bg/invoices/2403.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` = 2403
            LIMIT 1

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