I've two tables. Name of first is, let's say, Table_A:
| A_ID | Text |
|---|---|
| 1 | My name is {0}, and surname {1} |
| 2 | I live in [city:0] |
| ... | ... |
Second one is Table_B:
| B_ID | Number | Value |
|---|---|---|
| 1 | 0 | John |
| 1 | 1 | Smith |
| 2 | 0 | LA |
| ... | ... |
Column A_ID in Table_A is unique, but B_ID is not. Also, B_ID is foreign key. Additionally, parameters such as {0} or {1} might be different, i.e [str:0], [number:1] etc.
And task is: to write a PLSQL function which changes parameters in Table_A with the values of Table_B.
So, result should be:
| A_ID | Text |
|---|---|
| 1 | My name is John, and surname Smith |
| 2 | I live in LA |
| ... | ... |
P.S. the solution for the problem would be better, but any directions in which I should move on also will be a plus.