score:11

Accepted answer

union only works with the same element type. you could use:

var data = db.table1.select(p => new { p.value1, p.value2 })
     .union(db.table2.select(q => new { q.value1, q.value2 })
     .union(db.table3.select(r => new { value1 = r.alias1, value2 = r.other }); 

here the anonymous type serves as a common type to project all three tables onto, so that union can work.


Related Query

More Query from same tag