Select & Tables X Select & Views
От
Rodrigo Rezende
Тема
Select & Tables X Select & Views
Дата
Msg-id
38AD95C6.C8020910@hortolandia.marelli.it
Список
Дерево обсуждения
Re: [SQL] Select & Tables X Select & Views Rodrigo Rezende <Rodrigo.Rezende@hortolandia.marelli.it>
Re: [SQL] Select & Tables X Select & Views Tom Lane <tgl@sss.pgh.pa.us>
Hello all!, Using the following query : select * from taba, tabb; The result will be taba's number of rows * tabb's number of rows result = rows(taba) * rows(tabb) 1.ex.: taba : 1 2 3 tabb a b select * from taba, tabb; : 1 | a 2 | a 3 | a 1 | b 2 | b 3 | b This occurred because I didn't use the clause Join and Where... But, using a View instead of tabb(table), the number of rows was the same of the view 2. ex.: taba : 1 2 3 viewb a b select * from taba, viewb; : 1 | a 1 | b Why this occurred? I would like this second example returned the same as the first Thanks a lot, Rodrigo C. Rezende
В списке pgsql-sql по дате отправления
От: Mohit Marwaha
Дата: