Featured post

c# - Usage of Server Side Controls in MVC Frame work -

i using asp.net 4.0 , mvc 2.0 web application. project requiremrnt have use server side control in application not possibl in noraml case. ideally want use adrotator control , datalist control. i saw few samples , references in codepleax mvc controllib howwver found less useful. can tell how utilize theese controls in asp.net application along mvc. note: please provide functionalities related adrotator , datalist controls not equivalent functionalities thanks in advace. mvc pages not use normal .net solution makes use of normal .net components impossible. a normal .net page use event driven solution call different methods service side mvc use actions , view completly different way handle things. also, mvc not use viewstate normal .net controlls require. found article discussing mixing of normal .net , mvc.

Proper SQL datatables query writing -


i have table t1 3 columns id,c1,c2,c3 certains numbers. have different table t2 id,name values in id values of c1,c2,c3.

i unable write query can results

id | names of c1 | names of c2 | names of c3

can help.

one way write subqueries retrieve name each column:

select  t1.id ,       (select name t2 t2.id = t1.c1) c1name ,       (select name t2 t2.id = t1.c2) c2name ,       (select name t2 t2.id = t1.c3) c3name    t1 

or use tripe join:

select  t1.id ,       t2_1.name c1name ,       t2_2.name c2name ,       t2_3.name c3name    t1 join    t2 t2_1 on t1.c1 = t2_1.id join    t2 t2_2 on t1.c2 = t2_2.id join    t2 t2_3 on t1.c3 = t2_3.id 

Comments

Popular posts from this blog

c# - Usage of Server Side Controls in MVC Frame work -

cocoa - Nesting arrays into NSDictionary object (Objective-C) -

ios - Very simple iPhone App crashes on UILabel settext -