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
 SQL Server 2008 Forums
 Transact-SQL (2008)
 combining 2 select stmts

Author  Topic 

svibuk
Yak Posting Veteran

62 Posts

Posted - 2013-02-16 : 06:23:45
in asp.net i hve gridview with checkbox populated with data as
select d.id,d.name,d.age,h.height,p.photo from details d
inner join m_height h on m.height=h.height inner join m_photo p on p.id=m.id

the selected data[ checked data] from gridview is saved in another table
sel_details as insert into sel_details(sid)values(checkedbox id)

when the page is loaded next time i need that checkbox to be checked whose id is stored as sid in sel_details along with the rest of data

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2013-02-16 : 07:13:38
this is not a sql question. this need to be done at frond end ie through asp.net code. from sql, you just need to retrieve the set details


ie select sid from sel_details

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

svibuk
Yak Posting Veteran

62 Posts

Posted - 2013-02-16 : 07:58:09
thanks

was thinking if the 2 select stmts culd be combined to obtain the needed output
but i think i need to do it seperately and retrive in front end
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2013-02-16 : 08:53:43
yep...Indeed

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page
   

- Advertisement -