Not-5e44 | [IDEMPIERE] cboecking updated IDEMPIERE-2811 | 00:08 |
---|---|---|
Not-5e44 | [IDEMPIERE] The purpose of this ticket is to create a single primary key for m_productprice. Doing so gives m_productprice the same abilities as other tables with a single primary key. These abilities include: * accepting attachments * maintaining change log * etc... There are quite a few examples of of these tables. It is my hope that this ticket provides the model for doing the same to other tables if needed. Here | 00:08 |
Not-5e44 | is sql to help identify these tables: select t.tablename from ad_table t where 0= (select count (*) from ad_column c where c.ad_table_id = t.ad_table_id and c.iskey = 'Y' ) and t.isview='N' and lower(t.tablename) not like '%trl' and lower(t.tablename) not like 't_%' and lower(t.tablename) not like 'm_%ma' and lower(t.tablename) not like 'm_storage%' order by lower(t.tablename); Assumptions and Findings: * When | 00:09 |
Not-5e44 | creating the primary key, we can use the nextID db function to assign primary key values because of the below sub-bullets (per Carlos comment below) ** the 'M_ProductPrice' tableID record in AD_Sequence already exists. ** 'Enable Native Sequence' creates a sequence for tables even when there is no column flagged as primary key. The steps are described below. You will take the results of the below steps to hand-create | 00:09 |
Not-5e44 | the final migration script. Section 1 Attached "primary key steps 01.sql" 1. SQL - Drop current compound primary key 2. SQL - create new column NOT!! as primary key (example: M_ProductPrice_ID) 3. SQL - create temporary sequence 4. SQL - update new column with sequence 5. SQL - make column the primary key Section 2: execute attached SQL This section will be captured in a Log Migration Script 1. Enter Dictionary | 00:09 |
Not-5e44 | Maintenance username and password 2. Turn on Dictionary Maintenance and Log Migration Script 3. Find M_ProductPrice 4. Enable Change Log 5. Create M_ProductPrice_ID System Element ##. set Entity Type = Dictionary 6. Create M_ProductPrice_ID ##. make mandatory ##. do not allow copy 7. Find out every tab where table used (use AD_Client_ID -> Used in Field sub-tab) 8. Add key to every WT&F using the Create Fields | 00:09 |
Not-5e44 | process setting the Created Since date to yesterday To run migration script in a test environment: psql -U adempiere -d idempiere -f /tmp/mig....postgres.sql Section 3: update AD_Sequence just in case the count went above the default. Section 4: Create new patch in code. * regenerate model for M_ProductPrice * Update MProductPrice.java to remove "multi-key" exception Attach patch to ticket * Update M_PriceList_Create | 00:09 |
Not-5e44 | to include nextId Test cases: * Test to make sure all worked as expected - set GWAdmin role to isChangeLog = y and change a product->price * make sure new record get created and updated values * make sure updated records get correct details (updated and updatedby) * make sure records that existed before this change act correctly. * create a run Price Schema pass to make sure all works as expected * upgrade an | 00:09 |
Not-5e44 | existing system that is configured to use native sequences | 00:09 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2811 | 00:09 |
Not-5e44 | [IDEMPIERE] cboecking updated IDEMPIERE-2811 | 00:11 |
Not-5e44 | [IDEMPIERE] The purpose of this ticket is to create a single primary key for m_productprice. Doing so gives m_productprice the same abilities as other tables with a single primary key. These abilities include: * accepting attachments * maintaining change log * etc... There are quite a few examples of of these tables. It is my hope that this ticket provides the model for doing the same to other tables if needed. Here | 00:11 |
Not-5e44 | is sql to help identify these tables: select t.tablename from ad_table t where 0= (select count (*) from ad_column c where c.ad_table_id = t.ad_table_id and c.iskey = 'Y' ) and t.isview='N' and lower(t.tablename) not like '%trl' and lower(t.tablename) not like 't_%' and lower(t.tablename) not like 'm_%ma' and lower(t.tablename) not like 'm_storage%' order by lower(t.tablename); Assumptions and Findings: * When | 00:11 |
Not-5e44 | creating the primary key, we can use the nextID db function to assign primary key values because of the below sub-bullets (per Carlos comment below) ** the 'M_ProductPrice' tableID record in AD_Sequence already exists. ** 'Enable Native Sequence' creates a sequence for tables even when there is no column flagged as primary key. The steps are described below. You will take the results of the below steps to hand-create | 00:11 |
Not-5e44 | the final migration script. Section 1 Attached "primary key steps 01.sql" # SQL - Drop current compound primary key # SQL - create new column NOT!! as primary key (example: M_ProductPrice_ID) # SQL - update new column with nextID # SQL - make column the primary key Section 2: execute attached SQL This section will be captured in a Log Migration Script 1. Enter Dictionary Maintenance username and password 2. Turn on | 00:11 |
Not-5e44 | Dictionary Maintenance and Log Migration Script 3. Find M_ProductPrice 4. Enable Change Log 5. Create M_ProductPrice_ID System Element ##. set Entity Type = Dictionary 6. Create M_ProductPrice_ID ##. make mandatory ##. do not allow copy 7. Find out every tab where table used (use AD_Client_ID -> Used in Field sub-tab) 8. Add key to every WT&F using the Create Fields process setting the Created Since date to yesterday | 00:11 |
Not-5e44 | To run migration script in a test environment: psql -U adempiere -d idempiere -f /tmp/mig....postgres.sql Section 4: Create new patch in code. * regenerate model for M_ProductPrice * Update MProductPrice.java to remove "multi-key" exception Attach patch to ticket * Update M_PriceList_Create to include nextId Test cases: * Test to make sure all worked as expected - set GWAdmin role to isChangeLog = y and change a | 00:11 |
Not-5e44 | product->price * make sure new record get created and updated values * make sure updated records get correct details (updated and updatedby) * make sure records that existed before this change act correctly. * create a run Price Schema pass to make sure all works as expected * upgrade an existing system that is configured to use native sequences | 00:11 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2811 | 00:11 |
Not-5e44 | [IDEMPIERE] cboecking updated IDEMPIERE-2811 Attachment set to "None" | 00:11 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2811 | 00:11 |
*** ChuckBoecking has quit IRC | 00:31 | |
*** ChuckBoecking has joined #idempiere | 00:32 | |
Not-5e44 | [IDEMPIERE] cboecking updated IDEMPIERE-2811 Attachment set to "primary key steps V2.sql" | 00:32 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2811 | 00:32 |
Not-5e44 | [IDEMPIERE] cboecking updated IDEMPIERE-2811 Attachment set to "None" | 00:33 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2811 | 00:33 |
*** ChuckBoecking has quit IRC | 00:38 | |
Not-5e44 | [iDempiereDaily] jenkins built #459 completed (success) http://ci.idempiere.org/job/iDempiereDaily/459/ | 03:11 |
*** a42niem has joined #idempiere | 06:01 | |
*** mbozem has joined #idempiere | 06:08 | |
*** nmicoud has joined #idempiere | 06:17 | |
*** xapiens___ has joined #idempiere | 06:35 | |
*** xapiens_ has quit IRC | 06:37 | |
*** KermitTheFragger has joined #idempiere | 06:37 | |
Not-5e44 | [IDEMPIERE] norbert.bede created IDEMPIERE-2879 Attachment name not using printformat translation based user login language | 07:33 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2879 | 07:33 |
*** tsvikruha has joined #idempiere | 07:37 | |
*** mbozem has quit IRC | 07:37 | |
*** norbertbede has joined #idempiere | 07:41 | |
norbertbede | hi Nmicoud | 07:42 |
nmicoud | Hi | 07:42 |
norbertbede | need a bit advice to mail templates again | 07:42 |
norbertbede | do you have a bit time ? | 07:43 |
nmicoud | yes | 07:43 |
norbertbede | Question 1. https://idempiere.atlassian.net/browse/IDEMPIERE-2879 | 07:43 |
norbertbede | wdyt ? is it my miss or real issue. | 07:43 |
nmicoud | you want to send them as a backgound task ? | 07:44 |
norbertbede | no. in this case simple print to preview then click to send mail | 07:44 |
nmicoud | AFAIK, when you preview an invoice/order, it is the bpartner language which is used | 07:45 |
nmicoud | so, it will be displayed in the correct language | 07:45 |
norbertbede | ok but if not specific langiuage then client language could be applied | 07:45 |
nmicoud | but for other print formats, y ou would need to change it when sending the email (i mean regenerating the report) | 07:45 |
nmicoud | i think it's the case | 07:46 |
norbertbede | print format language is OK, only attachment name is wrong | 07:46 |
nmicoud | ah sorry | 07:46 |
nmicoud | didn't read well | 07:46 |
norbertbede | so i see my printed document in slovak language but if i click to email then attachment in english | 07:47 |
norbertbede | ok | 07:47 |
nmicoud | you send it from the 'standard' report panel ? | 07:47 |
norbertbede | yes | 07:47 |
nmicoud | it is the name of the report which is taken, not the translated one | 07:47 |
nmicoud | see ZkReportViewer.cmd_sendMail() | 07:48 |
nmicoud | around line 821 | 07:48 |
Not-5e44 | [IDEMPIERE] norbert.bede updated IDEMPIERE-2879 Attachment set to "attachemtntranslation.png" | 07:48 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2879 | 07:48 |
norbertbede | added a screenshot | 07:48 |
norbertbede | so needs to be fixed well | 07:49 |
nmicoud | yes | 07:49 |
norbertbede | ok. then we will fix it. thanks | 07:49 |
norbertbede | Question 2 | 07:49 |
norbertbede | is it possible select mail templates directly on email popup window ? | 07:49 |
nmicoud | i don't think so | 07:49 |
nmicoud | as mail template are set in other table | 07:50 |
Not-5e44 | [IDEMPIERE] norbert.bede updated IDEMPIERE-2879 | 07:50 |
Not-5e44 | [IDEMPIERE] IRC CHAT: you send it from the 'standard' report panel ? 09:45 norbertbede yes 09:45 nmicoud 09:45 it is the name of the report which is taken, not the translated one see ZkReportViewer.cmd_sendMail() around line 821 | 07:50 |
nmicoud | linked to organization | 07:50 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2879 | 07:50 |
nmicoud | But we could add a MailTemplate field on the EMailDialog | 07:51 |
norbertbede | in some cases we need to select a specific template | 07:51 |
norbertbede | would be cool | 07:51 |
nmicoud | But if we do that, we should also add some flags on the R_MailText table | 07:51 |
nmicoud | I mean, we shoulnd't propose some mails template (such as Reset Password or email signature) | 07:51 |
nmicoud | A kind of 'OnlyForInternalUse' | 07:52 |
norbertbede | i see | 07:52 |
norbertbede | i will create a ticket well | 07:53 |
norbertbede | for later imrpovement | 07:53 |
norbertbede | Question 3. sometimes would be helpful load contact from document | 07:53 |
norbertbede | e.g. want to send email to invoice contact person | 07:53 |
nmicoud | you want also a panel which give access to the bpartner / user tables ? | 07:54 |
nmicoud | from which you would select a line (eg : Joe Block <joe.block@company.com>) and it will be added in the recipient of the email ? | 07:55 |
norbertbede | but when i click to field To: then im able to select user | 07:55 |
norbertbede | im bit confused now | 07:55 |
norbertbede | from latest question | 07:55 |
nmicoud | what do you mean ? | 07:57 |
norbertbede | at this moment im able select <mailto:joe.block@company.com> on email dialog | 07:57 |
norbertbede | i want soon to pre populate this field based on document customer contact person | 07:57 |
norbertbede | so when user click to send email then mail template loaded automatically and customer contact will be populated to "TO" field | 07:58 |
nmicoud | i see the "To" field is always equals to "" | 07:58 |
nmicoud | so that would be possible to get the contact from the context of the window | 07:59 |
norbertbede | yes would be nice | 08:00 |
norbertbede | maybe improve mail template ? | 08:01 |
nmicoud | for mail template, add a flag to differenciate internal/external. But for find the correct contact, the logic could be hardcoded or maybe it could be done in the AD_PrintForm table | 08:02 |
nmicoud | (i never use this table) | 08:03 |
norbertbede | ok. very interesting ideas. thanks for discussion. | 08:05 |
nmicoud | yw | 08:06 |
nmicoud | hope it helps :) | 08:06 |
Not-5e44 | [IDEMPIERE] tsvikruha updated IDEMPIERE-2879 Attachment set to "IDEMPIERE-2879.patch" | 08:27 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2879 | 08:27 |
Not-5e44 | [IDEMPIERE] tsvikruha updated IDEMPIERE-2879 status set to "Peer Review Queue" | 08:27 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2879 | 08:27 |
Not-5e44 | [IDEMPIERE] tsvikruha updated IDEMPIERE-2879 labels set to "+Patch" | 08:27 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2879 | 08:27 |
Not-5e44 | [IDEMPIERE] tsvikruha updated IDEMPIERE-2879 assignee set to "Tomas Svikruha" | 08:27 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2879 | 08:27 |
Not-5e44 | [IDEMPIERE] tsvikruha updated IDEMPIERE-2879 | 08:30 |
Not-5e44 | [IDEMPIERE] I used name of report from dropdown of reports - name of report here should be translated so we can use it in file name and subject. | 08:30 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2879 | 08:30 |
*** norbertbede has quit IRC | 08:40 | |
*** norbertbede1 has joined #idempiere | 08:44 | |
*** mbozem has joined #idempiere | 09:04 | |
*** KermitTheFragger has quit IRC | 09:18 | |
norbertbede1 | nmicoud last question | 09:20 |
norbertbede1 | are you using BCC ? | 09:20 |
nmicoud | yes | 09:21 |
norbertbede1 | our user wants to receive copy and identify emails was send by users from idempiere to outside world | 09:21 |
norbertbede1 | i have enabled bcc | 09:21 |
norbertbede1 | but not enough experience how users able to identify email - to whom was sent | 09:21 |
norbertbede1 | e.g. in thunderbird | 09:21 |
nmicoud | when enabling bcc, the current user will receive a copy in his mal box. That could be enough to identify ? I mean sender = myself | 09:22 |
nmicoud | no ? | 09:22 |
nmicoud | with a rule, those mail can be moved in a special folder inside thunderbird | 09:22 |
norbertbede1 | we want to see the email was sent to which recipient | 09:23 |
nmicoud | from idempiere ? | 09:23 |
norbertbede1 | from this bcc email in mail client | 09:23 |
norbertbede1 | example | 09:23 |
norbertbede1 | im sending from me@norbertbede.com to nmicoud@ an email and bcc is me@norbertbede.com | 09:24 |
norbertbede1 | so i want to see in my mail client as me@norbertbede.com am sent to nmicoud@ an email | 09:24 |
norbertbede1 | probably its my luck of knowledge | 09:24 |
nmicoud | i understand what you want to do | 09:25 |
nmicoud | but i have no idea :- | 09:25 |
nmicoud | :( | 09:25 |
posde | bcc is by definition blind, ie. only the BCC recipient sees other non-BCC recipients. | 09:25 |
nmicoud | yeah | 09:26 |
nmicoud | perhaps that can be done througha plugin in thundebird ? | 09:26 |
norbertbede1 | im installing it | 09:27 |
norbertbede1 | let you know | 09:27 |
nmicoud | ok | 09:27 |
posde | The bcc information is NOT stored in the header for the other recipients. Nothing Thunderbird can do about it. | 09:27 |
norbertbede1 | ok i see | 09:28 |
norbertbede1 | but who was original recipient must be included | 09:28 |
norbertbede1 | just need to display and sort based on this in mail client | 09:28 |
posde | only if the original recipient is you | 09:28 |
posde | If you are the BCC recipient, you can look at the Envelope-To field. | 09:29 |
norbertbede1 | so you mean if reciepient is another person i cant be informat why im bccd ? | 09:29 |
norbertbede1 | ah | 09:30 |
norbertbede1 | sounds good | 09:30 |
posde | norbertbede1, if BCC: joe and BCC: mary - joe only sees joe in envelope-to, and mary only sees mary in envelope-to | 09:30 |
posde | norbertbede1, mary's mail message code does not contain any mentioning of joe, and vice versa. | 09:32 |
posde | If the mail contains a TO: jake, all three see jake, but jake doesn't see any mary or joe. | 09:32 |
norbertbede1 | posde do you understand what is my goal ? | 09:34 |
norbertbede1 | to see original to receipients | 09:34 |
norbertbede1 | it is new for me | 09:35 |
posde | norbertbede1, I think I am, and I am merely stating, that with BCC I doubt that you will have success. | 09:35 |
posde | Most of the time BCC is a political field, ie. you send a message to someone, and BCC your boss, so you see who the ignorant is. | 09:36 |
posde | Other use can be for mass mailings, where you don't want to fill up the header space with 10s or 100s of recipient addresses | 09:36 |
posde | And reports fall in the later category. | 09:37 |
*** mbozem has quit IRC | 09:43 | |
*** mbozem has joined #idempiere | 09:44 | |
norbertbede1 | hm. thanks | 09:45 |
Not-5e44 | [IDEMPIERE] deepak updated IDEMPIERE-2579 Attachment set to "Idempiere-2579_1.patch" | 10:31 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2579 | 10:31 |
Not-5e44 | [IDEMPIERE] deepak updated IDEMPIERE-2579 assignee set to "Carlos Antonio Ruiz Gomez" | 10:32 |
Not-5e44 | [IDEMPIERE] Carlos, Please note that attached updated patch Idempiere-2579_1 with all changes. This also contain changes you suggested in your code review. | 10:32 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2579 | 10:32 |
Not-5e44 | [IDEMPIERE] deepak updated IDEMPIERE-2579 status set to "Peer Review Queue" | 10:46 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2579 | 10:46 |
Not-5e44 | [IDEMPIERE] deepak updated IDEMPIERE-2579 Attachment set to "None" | 10:52 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2579 | 10:52 |
Not-5e44 | [IDEMPIERE] deepak updated IDEMPIERE-2579 Attachment set to "Idempiere-2579_1.patch" | 10:53 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2579 | 10:53 |
Not-5e44 | [IDEMPIERE] MZI updated IDEMPIERE-2867 | 10:53 |
Not-5e44 | [IDEMPIERE] Thank you [~carlosruiz_globalqss] for workaround. I tested it on demo server and we have realized , the problem was caused by our new re-activation function on Bank Statement . | 10:53 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2867 | 10:53 |
*** mbozem has quit IRC | 11:03 | |
*** norbertbede1 has quit IRC | 11:04 | |
*** norbertbede1 has joined #idempiere | 11:23 | |
*** norbertbede1 has quit IRC | 11:27 | |
*** ChuckBoecking has joined #idempiere | 12:23 | |
Not-5e44 | [IDEMPIERE] tsvikruha updated IDEMPIERE-2296 | 12:43 |
Not-5e44 | [IDEMPIERE] Today we faced problem when SQL default logic was not applied to process parameters. We needed to add sys config *ZK_SEQ_DEFAULT_VALUE_PANEL* for to value *"623"* to support old behaviour. I suggest to change this value also in code on line 582. *"62"* is not enough as default behaviour. | 12:43 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2296 | 12:43 |
Not-5e44 | [IDEMPIERE] cboecking updated IDEMPIERE-2811 | 12:45 |
Not-5e44 | [IDEMPIERE] The purpose of this ticket is to create a single primary key for M_ProductPrice. M_ProductPrice is an example of a link table that connects two other tables where the intersection includes attributes such as pricing. Traditionally, link tables do not have a single primary key. Instead, their key is the unique combination of the table IDs they connect. In iDempiere, it makes sense to give a link table a | 12:45 |
Not-5e44 | single primary key. Doing so gives M_ProductPrice the same abilities as other tables with a single primary key. These additional abilities include: * Accepting attachments * Maintaining change log * Audit log * Chat * Requests Since most link tables will not allow duplicates, you will typically create a unique constraint on the connecting foreign keys in addition to creating the primary key There are quite a few | 12:45 |
Not-5e44 | examples of of these tables. It is my hope that this ticket provides the model for doing the same to other tables if needed. Here is sql to help identify these tables: select t.tablename from ad_table t where 0= (select count (*) from ad_column c where c.ad_table_id = t.ad_table_id and c.iskey = 'Y' ) and t.isview='N' and lower(t.tablename) not like '%trl' and lower(t.tablename) not like 't_%' and lower(t.tablename) | 12:45 |
Not-5e44 | not like 'm_%ma' and lower(t.tablename) not like 'm_storage%' order by lower(t.tablename); The most obvious next tables to change for me include: * M_Cost * AD_User_Roles * Access tables (AD_Window_Access, AD_Task_Access, etc...) Assumptions and Findings: * When creating the primary key, we can use the nextID db function to assign primary key values because of the below sub-bullets (per Carlos comment below) ** the | 12:45 |
Not-5e44 | 'M_ProductPrice' tableID record in AD_Sequence already exists. ** 'Enable Native Sequence' creates a sequence for tables even when there is no column flagged as primary key. The steps are described below. You will take the results of the below steps to hand-create the final migration script. Section 1 Attached "primary key steps 01.sql" # SQL - Drop current compound primary key # SQL - create new column NOT!! as | 12:45 |
Not-5e44 | primary key (example: M_ProductPrice_ID) # SQL - update new column with nextID # SQL - make column the primary key Section 2: execute attached SQL This section will be captured in a Log Migration Script 1. Enter Dictionary Maintenance username and password 2. Turn on Dictionary Maintenance and Log Migration Script 3. Find M_ProductPrice 4. Enable Change Log 5. Create M_ProductPrice_ID System Element ##. set Entity | 12:45 |
Not-5e44 | Type = Dictionary 6. Create M_ProductPrice_ID ##. make mandatory ##. do not allow copy 7. Find out every tab where table used (use AD_Client_ID -> Used in Field sub-tab) 8. Add key to every WT&F using the Create Fields process setting the Created Since date to yesterday To run migration script in a test environment: psql -U adempiere -d idempiere -f /tmp/mig....postgres.sql Section 4: Create new patch in code. * | 12:45 |
Not-5e44 | regenerate model for M_ProductPrice * Update MProductPrice.java to remove "multi-key" exception Attach patch to ticket * Update M_PriceList_Create to include nextId Test cases: * Test to make sure all worked as expected - set GWAdmin role to isChangeLog = y and change a product->price * make sure new record get created and updated values * make sure updated records get correct details (updated and updatedby) * make | 12:45 |
Not-5e44 | sure records that existed before this change act correctly. * create a run Price Schema pass to make sure all works as expected * upgrade an existing system that is configured to use native sequences | 12:45 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2811 | 12:45 |
Not-5e44 | [IDEMPIERE] cboecking updated IDEMPIERE-2811 Attachment set to "None" | 12:49 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2811 | 12:49 |
Not-5e44 | [IDEMPIERE] cboecking updated IDEMPIERE-2811 Attachment set to "None" | 12:49 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2811 | 12:49 |
Not-5e44 | [IDEMPIERE] cboecking updated IDEMPIERE-2811 Attachment set to "migration_script_3151061084331536589_oracle.sql" | 12:49 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2811 | 12:49 |
*** tsvikruha has left #idempiere | 12:51 | |
Not-5e44 | [IDEMPIERE] cboecking updated IDEMPIERE-2811 | 12:54 |
Not-5e44 | [IDEMPIERE] Hi Carlos, Thank you for the feedback. I updated the migration scripts to remove the ad_treenode references. I updated the SQL to reflect your advice. Will you please test the "Primary Key Steps V2.sql" on an oracle machine to make sure the syntax does not throw an error? After you give the thumbs up on the oracle syntax, I will copy "Primary Key Steps V2.sql" into each of the migrations files, and | 12:54 |
Not-5e44 | perform on last round of testing on a new system to ensure the patch and scripts work as expected. Thanks, Chuck | 12:54 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2811 | 12:54 |
Not-5e44 | [IDEMPIERE] cboecking updated IDEMPIERE-2811 | 12:56 |
Not-5e44 | [IDEMPIERE] The purpose of this ticket is to create a single primary key for M_ProductPrice. M_ProductPrice is an example of a link table that connects two other tables where the intersection includes attributes such as pricing. Traditionally, link tables do not have a single primary key. Instead, their key is the unique combination of the table IDs they connect. In iDempiere, it makes sense to give a link table a | 12:56 |
Not-5e44 | single primary key. Doing so gives M_ProductPrice the same abilities as other tables with a single primary key. These additional abilities include: * Accepting attachments * Maintaining change log * Audit log * Chat * Requests Since most link tables will not allow duplicates, you will typically create a unique constraint on the connecting foreign keys in addition to creating the primary key There are quite a few | 12:56 |
Not-5e44 | examples of of these tables. It is my hope that this ticket provides the model for doing the same to other tables if needed. Here is sql to help identify these tables: select t.tablename from ad_table t where 0= (select count (*) from ad_column c where c.ad_table_id = t.ad_table_id and c.iskey = 'Y' ) and t.isview='N' and lower(t.tablename) not like '%trl' and lower(t.tablename) not like 't_%' and lower(t.tablename) | 12:56 |
Not-5e44 | not like 'm_%ma' and lower(t.tablename) not like 'm_storage%' order by lower(t.tablename); The most obvious next tables to change for me include: * M_Cost * AD_User_Roles * Access tables (AD_Window_Access, AD_Task_Access, etc...) Assumptions and Findings: * When creating the primary key, we can use the nextID db function to assign primary key values because of the below sub-bullets (per Carlos comment below) ** the | 12:56 |
Not-5e44 | 'M_ProductPrice' tableID record in AD_Sequence already exists. ** 'Enable Native Sequence' creates a sequence for tables even when there is no column flagged as primary key. The steps are described below. You will take the results of the below steps to hand-create the final migration script. Section 1 Attached "primary key steps 01.sql" # SQL - Drop current compound primary key # SQL - create new column NOT!! as | 12:56 |
Not-5e44 | primary key (example: M_ProductPrice_ID) # SQL - update new column with nextID # SQL - make column the primary key Section 2: execute attached SQL This section will be captured in a Log Migration Script 1. Enter Dictionary Maintenance username and password 2. Turn on Dictionary Maintenance and Log Migration Script 3. Find M_ProductPrice 4. Enable Change Log 5. Create M_ProductPrice_ID System Element ##. set Entity | 12:56 |
Not-5e44 | Type = Dictionary 6. Create M_ProductPrice_ID ##. make mandatory ##. do not allow copy 7. Find out every tab where table used (use AD_Client_ID -> Used in Field sub-tab) 8. Add key to every WT&F using the Create Fields process setting the Created Since date to yesterday To run migration script in a test environment: psql -U adempiere -d idempiere -f /tmp/mig....postgres.sql Section 3: Create new patch in code. * | 12:56 |
Not-5e44 | regenerate model for M_ProductPrice * Update MProductPrice.java to remove "multi-key" exception Attach patch to ticket * Update M_PriceList_Create to include nextId Test cases: * Test to make sure all worked as expected - set GWAdmin role to isChangeLog = y and change a product->price * make sure new record get created and updated values * make sure updated records get correct details (updated and updatedby) * make | 12:56 |
Not-5e44 | sure records that existed before this change act correctly. * create a run Price Schema pass to make sure all works as expected * upgrade an existing system that is configured to use native sequences | 12:56 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2811 | 12:56 |
Not-5e44 | [IDEMPIERE] cboecking updated IDEMPIERE-2811 | 12:58 |
Not-5e44 | [IDEMPIERE] The purpose of this ticket is to create a single primary key for M_ProductPrice. M_ProductPrice is an example of a link table that connects two other tables where the intersection includes attributes such as pricing. Traditionally, link tables do not have a single primary key. Instead, their key is the unique combination of the table IDs they connect. In iDempiere, it makes sense to give a link table a | 12:58 |
Not-5e44 | single primary key. Doing so gives M_ProductPrice the same abilities as other tables with a single primary key. These additional abilities include: * Accepting attachments * Maintaining change log * Audit log * Chat * Requests Since most link tables will not allow duplicates, you will typically create a unique constraint on the connecting foreign keys in addition to creating the primary key There are quite a few | 12:58 |
Not-5e44 | examples of of these tables. It is my hope that this ticket provides the model for doing the same to other tables if needed. Here is sql to help identify these tables: select t.tablename from ad_table t where 0= (select count (*) from ad_column c where c.ad_table_id = t.ad_table_id and c.iskey = 'Y' ) and t.isview='N' and lower(t.tablename) not like '%trl' and lower(t.tablename) not like 't_%' and lower(t.tablename) | 12:58 |
Not-5e44 | not like 'm_%ma' and lower(t.tablename) not like 'm_storage%' order by lower(t.tablename); The most obvious next tables to change for me include: * M_Cost * AD_User_Roles * Access tables (AD_Window_Access, AD_Task_Access, etc...) Assumptions and Findings: * When creating the primary key, we can use the nextID db function to assign primary key values because of the below sub-bullets (per Carlos comment below) ** the | 12:58 |
Not-5e44 | 'M_ProductPrice' tableID record in AD_Sequence already exists. ** 'Enable Native Sequence' creates a sequence for tables even when there is no column flagged as primary key. The steps are described below. You will take the results of the below steps to hand-create the final migration script. Section 1 Attached "primary key steps 01.sql" # SQL - Drop current compound primary key # SQL - create new column NOT!! as | 12:58 |
Not-5e44 | primary key (example: M_ProductPrice_ID) # SQL - update new column with nextID # SQL - make column the primary key Section 2: execute attached SQL This section will be captured in a Log Migration Script # Enter Dictionary Maintenance username and password # Turn on Dictionary Maintenance and Log Migration Script # Find M_ProductPrice # Enable Change Log # Create M_ProductPrice_ID System Element ## set Entity Type = | 12:58 |
Not-5e44 | Dictionary # Create M_ProductPrice_ID ## make mandatory ## do not allow copy # Find out every tab where table used (use AD_Client_ID -> Used in Field sub-tab) # Add key to every WT&F using the Create Fields process setting the Created Since date to yesterday To run migration script in a test environment: psql -U adempiere -d idempiere -f /tmp/mig....postgres.sql Section 3: Create new patch in code. * regenerate model | 12:58 |
Not-5e44 | for M_ProductPrice * Update MProductPrice.java to remove "multi-key" exception Attach patch to ticket * Update M_PriceList_Create to include nextId Test cases: * Test to make sure all worked as expected - set GWAdmin role to isChangeLog = y and change a product->price * make sure new record get created and updated values * make sure updated records get correct details (updated and updatedby) * make sure records that | 12:58 |
Not-5e44 | existed before this change act correctly. * create a run Price Schema pass to make sure all works as expected * upgrade an existing system that is configured to use native sequences | 12:58 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2811 | 12:58 |
*** posde has quit IRC | 13:14 | |
*** posde has joined #idempiere | 13:33 | |
*** mbozem has joined #idempiere | 13:41 | |
*** posde has quit IRC | 13:42 | |
*** posde has joined #idempiere | 13:44 | |
Not-5e44 | [IDEMPIERE] hieplq updated IDEMPIERE-2296 | 13:46 |
Not-5e44 | [IDEMPIERE] Hi [~tsvikruha], now it can configuration, so let implement decide it. default value of system for process parameter and infoWindow parameter follow old logic of parameter in infoWindow, it don't use type and database default value. i think it's acceptable. | 13:46 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2296 | 13:46 |
Not-5e44 | [IDEMPIERE] tsvikruha updated IDEMPIERE-2296 | 13:55 |
Not-5e44 | [IDEMPIERE] [~hieplq] I mean default logic from process parameter like @SQL=SELECT.... is not considering now which breaks old logic.. Also I understand that it's possible to set sys config, but we should never break old logic of system :) | 13:55 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2296 | 13:55 |
*** ChuckBoecking has quit IRC | 14:30 | |
*** mbozem has quit IRC | 14:35 | |
*** ChuckBoecking has joined #idempiere | 14:44 | |
*** nmicoud has quit IRC | 16:03 | |
*** nmicoud has joined #idempiere | 17:46 | |
Not-5e44 | [IDEMPIERE] jgarcia updated IDEMPIERE-2869 Attachment set to "ChargeWithtaxes.patch" | 17:47 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2869 | 17:47 |
Not-5e44 | [IDEMPIERE] jgarcia updated IDEMPIERE-2869 | 17:48 |
Not-5e44 | [IDEMPIERE] [^ChargeWithtaxes.patch] Attached You will find the pacth file with the changes. | 17:48 |
Not-5e44 | [IDEMPIERE] http://idempiere.atlassian.net/browse/IDEMPIERE-2869 | 17:48 |
*** nmicoud has quit IRC | 18:46 | |
*** mbozem has joined #idempiere | 19:12 | |
*** mbozem has quit IRC | 20:01 | |
*** a42niem has quit IRC | 21:59 |
Generated by irclog2html.py 2.14.0 by Marius Gedminas - find it at mg.pov.lt!