Exemple #1
0
 def crossJoin(self):
     self.cursor.execute("SELECT * FROM Claim CROSS JOIN Member M;")
     writeTable(self.cursor.fetchall(), "cross join")
Exemple #2
0
 def rightInnerJoin(self):
     self.cursor.execute(
         "SELECT M.MemberID, C.ClaimAmt, M.FirstName, M.LastName FROM Claim C RIGHT OUTER JOIN Member M ON C.MemberID = M.MemberID;"
     )
     writeTable(self.cursor.fetchall(), "right outer join")
Exemple #3
0
 def leftOuterJoin(self):
     self.cursor.execute(
         "SELECT C.ClaimAmt, M.FirstName, M.LastName FROM Claim C LEFT OUTER JOIN Member M ON C.MemberID = M.MemberID;"
     )
     writeTable(self.cursor.fetchall(), "left outer join")
Exemple #4
0
 def innerJoin(self):
     self.cursor.execute(
         "SELECT C.ClaimAmt, M.FirstName, M.LastName FROM Claim C INNER JOIN Member M ON C.MemberID = M.MemberID;"
     )
     writeTable(self.cursor.fetchall(), "inner join")
Exemple #5
0
 def getClaim(self):
     self.cursor.execute("SELECT * FROM Claim;")
     writeTable(self.cursor.fetchall(), "Claim table")
Exemple #6
0
 def getMembers(self):
     self.cursor.execute("SELECT * FROM Member;")
     writeTable(self.cursor.fetchall(), "Member table")