I recently have been working on MANY jobs that require me to check a column for a code in a document and this code has some sort of value attached to it in another column, then on another document i have the same set up but with a different value, i need to make the changes on every code that matches while leaving the value in the ones that dont match
here a small example of the idea where in the first document the code 1 and 3 dont match with the second document so i change the value in the second document
(btw it dont need to be the 2 documents if it is possible to just grab the value column, add in the document 2 on and then work with the values in the same document that also would already help enough)
so TL;DR if document 1 code matches document 2 then value of document 2 becomes value of Document 1
(or also a possibility)
Joiner both documents and then do this process on the same document so i can have a column with the correct values
For anyone interested to know more on how to do If Else statements in KNIME there are already many discussion so give forum search a try. For example here is one topic:
it kinda work but the problem is on the cell replacer (as far as i know) you would look at the code of document 1 compare with code in document 2 and on document 2 exchange the code with the value of document one, i need the value to be exchanged in the column value in the document 2 with document one, reading your documents maybe column expression would work
something like
Joiner both documents to have both in the same document and the same line, then in column expression
Some cases, i used the rule engine and define a variable to set all cases, even the cases that don’t need attention. For each case, I set integer number to identify it… start from “0” to “x” cases.
I made it to use as port matches at switch/case nodes… the ports start with “0” and you can add many ports for each case… Just put after the rule engine a table row to variable node and connect just this port at the switch node as flow variable.
i had to look in to it but i made it work i joiner all in the same document and then i did in the column expression
if (column(“Code1”) == column(“Code2”))
{column(“Value 1”)}
else
{column(“Value 2”)};
was having a LOT or problems with the actual code but hey now it works so good enougth XD