1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Joining Update query

Discussion in 'MySQL' started by johnberman, Aug 27, 2017.

  1. #1
    Hi
    I have a number of queries like this

    UPDATE duration_events b
    JOIN meteor_events p
    ON p.event_id = b.event_id
    SET b.image = p.image;

    and

    UPDATE duration_matched b
    JOIN meteor_events p
    ON p.event_id = b.event_id

    SET b.image = p.image;

    Rather than have 2 separate queries can I have these in one query - i did try but had syntax issues.

    Thanks
     
    johnberman, Aug 27, 2017 IP