I have two tables, TABLE_1 and TABLE_2 and I want to create a view with some fields of both where the id_event (existing in both) is equal.
CREATE TABLE table_1 (
id INT,
id_event INT,
col1_t1 varchar(255),
...);
CREATE TABLE table_2 (
id INT,
id_event INT,
col1_t2 varchar(255),
col2_t2 varchar(255),
...);
The purpose is to have the view with the fields TABLE1.id, TABLE2.id, TABLE2.col1_t2 and TABLE2.col2_t2