Results 1 to 2 of 2

Thread: Regarding Join

  1. #1
    adeeb is offline Member
    Join Date
    May 2008
    Rep Power

    Default Regarding Join

    I actually have three rows in addissue table but when i run this query i am getting nine. Here expiry is a view.
    Java Code:
    select a.added,a.curr_date,e.days from addissue a,expiry e;
    So please any body correct me.
    Thanks and regards.

  2. #2
    danielstoner's Avatar
    danielstoner is offline Senior Member
    Join Date
    Apr 2008
    Rep Power


    You create a cartesian product with this query. So you get all the possible combinations of rows from the two source tables. To get only what you want you have to create a join. The simplest way is to add a where clause and to specify what column in "expiry" refers to what column in "addissue":

    Java Code:
    where e.issue_id =
    Daniel @ []
    Language is froth on the surface of thought

Similar Threads

  1. How to use join() method
    By Java Tip in forum java.lang
    Replies: 0
    Last Post: 04-09-2008, 07:33 PM
  2. i'm happy to join this forum
    By sivasayanth in forum Introductions
    Replies: 1
    Last Post: 12-25-2007, 09:56 AM

Posting Permissions

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