Home Forums SQL Server 7,2000 T-SQL Incorrect syntax near the keyword 'IF'. RE: Incorrect syntax near the keyword 'IF'.

  • Ah, now I see. You cannot use an IF construct with an INSERT statement. Look in BOL for INSERT; it must be INSERT INTO....VALUES or INSERT INTO.....SELECT.

    John Rowan

    ======================================================
    ======================================================
    Forum Etiquette: How to post data/code on a forum to get the best help[/url] - by Jeff Moden