i'm confused on what you are doing... Note that if you do this:
the second line overwrites what you got in the first line. Did you mean something like this:
Now, you can do this. you then have to define a getRegistration method that takes TWO strings as arguments. I am also assuming that the getReg method you pasted in is really getRegistration()???
These little details make a huge difference.
You should get in the habit now of paying attention to things like that. Your life (and anybody who reads your code) will be much simpler if you are more accurate in saying what you mean.
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors