I have a custom table called flagged_products
which lists flagged products like this:
+-----------+------------+---------------------+
| entity_id | product_id | flagged_on |
+-----------+------------+---------------------+
| 1 | 356534 | 2019-03-01 12:45:20 |
| 2 | 654657 | 2019-01-07 05:52:09 |
| 3 | 345477 | 2019-03-23 09:34:07 |
| 4 | 114673 | 2019-04-11 15:45:17 |
+-----------+------------+---------------------+
I want to join this with the catalog/product model to list all the names of the products which have been flagged like this:
+-----------+--------------+---------------------+
| entity_id | product_name | flagged_on |
+-----------+--------------+---------------------+
| 356534 | Product 1 | 2019-03-01 12:45:20 |
| 654657 | Product 2 | 2019-01-07 05:52:09 |
| 345477 | Product 3 | 2019-03-23 09:34:07 |
| 114673 | Product 4 | 2019-04-11 15:45:17 |
+-----------+--------------+---------------------+
However, since the product name is a part of the EAV tables, i'm not really sure how to get this information.
Would appreciate help on how this can be achieved with Magento 1