Insert into MySQL table all Sundays and Saturdays from current year
<p>I have this tiny table with just "fecha" field in it.</p>

<p>I need a <code>MySQL</code> query that inserts every sunday and saturday of the year to the table.</p>

<p><strong>My own research</strong> got me to the point where i know i need to do something like this:</p>

<pre><code>DECLARE diaRecorrido date();
SET diaRecorrido = date(now());

WHILE DATEPART(WEEKDAY,diaRecorrido) = 1 or DATEPART(WEEKDAY,diaRecorrido) = 7
    BEGIN
        INSERT INTO feriados (fecha)
        VALUES (diaRecorrido)

    IF diaRecorrido=2017/01/01
    THEN
    LEAVE lazo;
    END IF;

    END;
</code></pre>

<p>Any guidance is much apreciated!</p>