It depends on what exactly you want to do with the data. At the moment, your code will not compile because it is trying to create an anonymous type with several properties, all called "arg", but I assume that you really have a more reasonable request.
Ultimately, the fact that you use multiple tables does not matter here - you get only one element of the result at a time: the fact that each element of the result contains data from several tables, neither here nor there in terms of how you address him.
Now I just noticed that you are saying that you want to “extract data and convert to string”. If possible, you should express this in your request. You can do this in the database, or you may need to force the final part of the execution locally, for example:
Now you don’t have to do it this way, but this is probably the best approach, at least with the amount of information you gave us. If you can tell us more about how you are trying to combine data from several tables, we can help you more.
EDIT: Ok, now you have given us a little more information, I suspect you want:
var query = from a in context.a join b in context.bs on a.prikey equals b.forkey join c in context.cs on b.prikey equals c.forkey join d in context.ds on c.prikey equals d.forkey where ... select new string[] { a.arg, b.arg, c.arg, d.arg }; string[] results = query.First();
I have not tried creating arrays in LINQ to SQL ... that might work, or you might need to go through an anonymous type and AsEnumerable
according to the previous part of my answer.
You should also think about what you want if there are no results or multiple results.
EDIT: after seeing the edited question, you can really handle multiple tables in the same way as a single table. You would use exactly the same code to process the result once it was projected into an anonymous type:
var query = from a in context.as join b in context.bs on a.prikey equals b.forkey join c in context.cs on b.prikey equals c.forkey join d in context.ds on c.prikey equals d.forkey where ... select new { a.Name, a.Age, b.Gender }; var result = query.First();