Results 1 to 2 of 2
  1. #1
    Join Date
    May 2003
    Posts
    40

    Unanswered: combining two select staements

    Folks

    I have two select statements which gives two counts ie two numbers.


    select 'count' = count(*) from account

    select 'count1' = count(*) from employee


    I want to combine these two select statements and write one select statement where I can get two columns 'count' and 'count1' with the respective values.

    The result should be EX:

    count count1
    3 5


    Thanks

  2. #2
    Join Date
    Sep 2003
    Location
    Dallas, Texas
    Posts
    311

    Re: combining two select staements

    select (select count(*) from account) as 'Count',
    (select count(*) from employee) as 'Count1'

Posting Permissions

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