Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 query help

Author  Topic 

sangeetabal
Starting Member

3 Posts

Posted - 2012-01-18 : 00:57:53
I have a two tables with structure

table1

groupid groupname grouptype
1001 test1 1
1002 test2 100
1003 test3 100
1004 test4 1

table2

groupid name propvalue
1001 group.type 2
1001 group.case Case1
1001 group.follow follow1

1002 group.type 3
1002 group.case Case2
1002 group.follow follow2

1003 group.type 4
1003 group.case Case3
1003 group.follow follow3

1004 group.type 5
1004 group.case Case4
1004 group.follow follow4

I need the output with group whose grouptype(3rd column of first table) is 100 and corresponding propvalue with name as group.type and group.case like :-

groupid groupname propvalue(propvalue of group.type from second table) propvalue(propvalue of group.case from second table)
1002 test2 2 Case1
1003 test3 3 Case3

Not able to use join properly :( new bie

sangeetabal
Starting Member

3 Posts

Posted - 2012-01-18 : 01:39:35
its solved
Go to Top of Page

sangeetabal
Starting Member

3 Posts

Posted - 2012-01-18 : 01:39:53
its solved
Go to Top of Page
   

- Advertisement -