If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > Some HELP with MS SQL

Closed Thread
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 10-25-10, 11:28
Lenny77 Lenny77 is offline
Registered User
 
Join Date: Jul 2009
Location: NY
Posts: 886
Question Some HELP with MS SQL

What is the equivalent between DB2 JOIN TABLE and MS SQL :

In DB2:

Code:
select * from
table1 t1 
JOIN TABLE
(select t2.* from table2 t2
where t2.clmn2 = t1.clmn1
and t2.clmn3 = t1.clmn3) tt
on  1 = 1 
Show me how it'll look in MS SQL .

Thanks
  #2 (permalink)  
Old 10-25-10, 12:05
r937 r937 is offline
SQL Consultant
 
Join Date: Apr 2002
Location: Toronto, Canada
Posts: 19,524
wow, that's weird

Code:
SELECT * 
  FROM table1 AS t1 
INNER
  JOIN table2 AS t2
    ON t2.clmn2 = t1.clmn1
   AND t2.clmn3 = t1.clmn3
__________________
r937.com | rudy.ca
please visit Simply SQL and buy my book
  #3 (permalink)  
Old 10-25-10, 12:21
pootle flump pootle flump is offline
King of Understatement
 
Join Date: Feb 2004
Location: One Flump in One Place
Posts: 14,905
Please don't double post Lenny. I've locked this one.
__________________
Testimonial:
Quote:
pootle flump
ur codings are working excelent.
Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On