Quantcast
Channel: SQLServerCentral » SQL Server 2014 » Development - SQL Server 2014 » Latest topics
Viewing all articles
Browse latest Browse all 3145

Two Select statements without UNION

$
0
0
I have two tablesDept table with 8 recordsLogins table with 23 recordsbelow query should display 31 records, but it is displaying 184 records (8*23=184).i want below query to display 31 records without using UNION - Please suggstselect d.name from dept d, logins lwhere d.dept_id='ICT' and l.login_id=10

Viewing all articles
Browse latest Browse all 3145

Latest Images

Trending Articles



Latest Images