This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| SELECT schemaname||'.'||tablename as table, | |
| pg_size_pretty (pg_total_relation_size(schemaname||'.'||tablename)) as size | |
| from pg_tables | |
| order by pg_total_relation_size(schemaname||'.'||tablename) desc; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| journals = env['account.journal'].search([]) | |
| sequence_list = '' | |
| for journal in journals: | |
| jmove = env['account.move'].search([('journal_id','=',journal.id)],order = 'date desc', limit = 1) | |
| sequence_list += '{} (#{} {})\n'.format(jmove.name, journal.id,journal.name) | |
| raise Warning(sequence_list) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Specify the date where the sequence was broken (e.g. most probably the migration to prod date) | |
| date_sequence = '20XX-XX-XX' | |
| # Specify ID of concerned journals, leave empty to fix for all journals | |
| journal_ids = [] | |
| corrected_moves=[] | |
| query = """ | |
| SELECT id,journal_id, date, name | |
| FROM ( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # FOR VERSION 10,11,12,13,... | |
| # Set sessions ids between the brackets, separated by a coma | |
| # I.E. SESSION_ID = [12, 18, 132] or SESSION_ID = [4] | |
| SESSION_ID = [] | |
| MODE = 'check' | |
| # DO NOT MODIFY | |
| VALID_VERSIONS = (10, 11, 12, 13,) | |
| VALID_SESSION_STATES = ('opened', 'closing_control') | |
| VALID_MODES = ('check', 'repair') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # FOR VERSION 12, 12.3, 13 | |
| # Set sessions ids between the brackets, separated by a coma | |
| # I.E. SESSION_ID = [12, 18, 132] or SESSION_ID = [4] | |
| SESSION_IDS = [] | |
| FIELDS_TO_DISPLAY_IN_CSV = [ # Comment the field you don't want to see | |
| 'name', | |
| 'price_unit', | |
| 'tax_is', | |
| 'tax_should_be', | |
| 'diff_tax', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| TO DUPLICATE A DB DIRECTLY FROM SUPPORT PAGE | |
| https://XXXXX.odoo.com/saas_worker/dup?to=YYYYY&support=True |