Skip to content
Advertisement

How to update specific column with values from another table

I have a table called “bug_table” that looks like this:

and a table called “bug_revision_table” that looks like this:

Now comes the question:

How can I modify the timestamp of each id from the first table with the latest/most recent one from the second table?

As you can see, each bug_id can have multiple revisions with different timestamps. I’m only interested in the latest timestamp.

EDIT: This is how the table should look afterwards:

Advertisement

Answer

You could use updated with join

or could be you looking for a unique values for all the ids

User contributions licensed under: CC BY-SA
3 People found this is helpful
Advertisement