Results 1 to 2 of 2
  1. #1
    Join Date
    Mar 2004

    Unanswered: Question about a Select Statement


    I'm quite new to SQL and so my question may sound a bit strange.

    Let me say I have the primary Keys 2049, 2090,4080,7803

    For those 4 primary Keys I want to Select the rows from a table. How ca I do this in 1 SQL-Statement.

    My way until now: Select [column-List] From tab1 Where ID=2049;
    Select [column-list] From tab1 Where ID = 2090

    So I split up into 4 Statements

    There MUST be a way doing this in one statement!!!!!

    Can you help me?

    Kind regards

  2. #2
    Join Date
    Sep 2002
    Provided Answers: 1

    Re: Question about a Select Statement

    Try this:

    where ID in (2049,2090,4080,7803)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts