Tuesday, January 23, 2018

Inner join with where clause

SQL Programming language Joins syntax  are join two or more tables. Most usable SQL join is INNER JOIN. It’s a most common join. This join check both table match with the condition. INNER JOIN possible more then two table, it can work with  multiple table. It’s join two or more table based on there matching field.In this query we see inner join with where condition. 

      SELECT table1.id  FROM table1
      INNER JOIN table2
      ON table2.id = table1.id
      WHERE table2.date = '1/23/2018'
      AND serial= '2';

No comments:

Post a Comment