Export templates - Unknown column 'label_size' in 'field list'

Ask your questions here.
Post Reply
bigart
Posts: 29
Joined: 14 Jan 2021, 12:22
Name: Art Ko
Location: PL
Company Name: IPR

Export templates - Unknown column 'label_size' in 'field list'

Post by bigart »

Hi,
we have a problem when trying to add new export template (extensions).
After completing all form fields and click save we always get error like below.
Where is the problem ?

Code: Select all

Database Error: 1054 - Unknown column 'label_size' in 'field list'
Query: insert into app_ext_export_templates (name, entities_id, type, label_size, button_title, button_position, button_color, button_icon, is_active, sort_order, users_groups, assigned_to, template_filename, save_as, save_attachments, template_css, page_orientation, split_into_pages, template_header, template_footer) values ('test', '59', 'docx', '', 'test', 'menu_with_selected', '#FFEB3B', '', '1', '1', '', '', '', '', '', '', 'portrait', '1', '', '')
Page: /index.php?module=ext/templates/export_templates&action=save&token=ej1cZdDRJz
#0 includes/functions/database.php(87): mysqli_query(Object(mysqli), 'insert into app...')
#1 includes/functions/database.php(221): db_query('insert into app...', false)
#2 plugins/ext/modules/templates/actions/export_templates.php(112): db_perform('app_ext_export_...', Array)
#3 index.php(20): require('/home/phpolmozb...')
#4 {main}
User avatar
support
Site Admin
Posts: 6204
Joined: 19 Oct 2014, 18:22
Name: Sergey Kharchishin
Location: Russia, Evpatoriya

Re: Export templates - Unknown column 'label_size' in 'field list'

Post by support »

this column was added in 2.8
Make sure you have run this /install/ext_autoupdate/from_2.7_to_2.8.php
For more details you can see https://docs.rukovoditel.net/index.php?p=63

If app said "Already done" then you can manually add this column by run query in phpmyadmin

Code: Select all

ALTER TABLE `app_ext_export_templates` ADD `label_size` VARCHAR(16) NOT NULL AFTER `type`;
All sql that required for 2.8 here install\db_updates\ext\ext_2.8.sql
bigart
Posts: 29
Joined: 14 Jan 2021, 12:22
Name: Art Ko
Location: PL
Company Name: IPR

Re: Export templates - Unknown column 'label_size' in 'field list'

Post by bigart »

thank you

next step:
execute /install/ext_autoupdate/from_3.0_to_3.1.php

I get:

Processing...
ALTER TABLE `app_ext_export_templates` ADD `save_attachments` VARCHAR(255) NOT NULL AFTER `save_as`
1054
Unknown column 'save_as' in 'app_ext_export_templates'
User avatar
support
Site Admin
Posts: 6204
Joined: 19 Oct 2014, 18:22
Name: Sergey Kharchishin
Location: Russia, Evpatoriya

Re: Export templates - Unknown column 'label_size' in 'field list'

Post by support »

Which version you have used before update?
bigart
Posts: 29
Joined: 14 Jan 2021, 12:22
Name: Art Ko
Location: PL
Company Name: IPR

Re: Export templates - Unknown column 'label_size' in 'field list'

Post by bigart »

We use:
Rukovoditel 3.2.1
Extension 3.2.1

Previous version 3.1, 3.0 and 2.9, 2.8 I think.
User avatar
support
Site Admin
Posts: 6204
Joined: 19 Oct 2014, 18:22
Name: Sergey Kharchishin
Location: Russia, Evpatoriya

Re: Export templates - Unknown column 'label_size' in 'field list'

Post by support »

Try to run next script. Just download /install folder and open next urls in browser.

/install/autoupdate/from_2.7_to_2.8.php
/install/ext_autoupdate/from_2.7_to_2.8.php

/install/autoupdate/from_2.8_to_2.9.php
/install/ext_autoupdate/from_2.8_to_2.9.php

/install/autoupdate/from_2.9_to_3.0.php
/install/ext_autoupdate/from_2.9_to_3.0.php

/install/ext_autoupdate/from_3.0_to_3.1.php
bigart
Posts: 29
Joined: 14 Jan 2021, 12:22
Name: Art Ko
Location: PL
Company Name: IPR

Re: Export templates - Unknown column 'label_size' in 'field list'

Post by bigart »

I did it and all urls return "You have already run this update"
User avatar
support
Site Admin
Posts: 6204
Joined: 19 Oct 2014, 18:22
Name: Sergey Kharchishin
Location: Russia, Evpatoriya

Re: Export templates - Unknown column 'label_size' in 'field list'

Post by support »

Then try to add this one under phpmyadmin

Code: Select all

ALTER TABLE `app_ext_export_templates` ADD `label_size` VARCHAR(16) NOT NULL AFTER `type`;
bigart
Posts: 29
Joined: 14 Jan 2021, 12:22
Name: Art Ko
Location: PL
Company Name: IPR

Re: Export templates - Unknown column 'label_size' in 'field list'

Post by bigart »

hi,
you already mentioned it above and I did it
Now I have a problem with:

Code: Select all

ALTER TABLE `app_ext_export_templates` ADD `save_attachments` VARCHAR(255) NOT NULL AFTER `save_as`
1054
Unknown column 'save_as' in 'app_ext_export_templates'
User avatar
support
Site Admin
Posts: 6204
Joined: 19 Oct 2014, 18:22
Name: Sergey Kharchishin
Location: Russia, Evpatoriya

Re: Export templates - Unknown column 'label_size' in 'field list'

Post by support »

run next to add column save_as

Code: Select all

ALTER TABLE `app_ext_export_templates` ADD `save_as` VARCHAR(32) NOT NULL AFTER `template_filename`;
Post Reply