and welcome to the exciting world of java snippets! Your code looks almost correct. The only thing wrong seems to be how you "store" the data. It is enough to just write the data into the right variable, with no extra method call. Something like this:
Marlin thank you for your help, I copied the code but I could not generate the new column. I wonder if could you please help me checking what is wrong.