string sql = "SELECT top 1 A.replyId, A.questionId, C.employeeCode, C.firstname AS qName, C.lastname AS qSurname, B.code, B.topic, B.description, A.description AS rDesc, B.createdId, B.createdDate ";
sql += "FROM HR_CALLCENTER.dbo.reply AS A INNER JOIN HR_CALLCENTER.dbo.question AS B ON A.questionId = B.questionId ";
sql += "INNER JOIN HR_CALLCENTER.dbo.users AS C ON B.createdId = C.employeeId ";
sql += "WHERE A.replyId = '" + id + "'";
var reply = db.replys.SqlQuery(sql);
Code
SELECT
A.replyId,
A.questionId,
C.employeeCode,
D.employeeCode,
C.firstname AS qName,
C.lastname AS qSurname,
B.code,
B.topic,
B.description AS qDesc,
A.description AS rDesc,
B.createdId,
B.createdDate
FROM
HR_CALLCENTER.dbo.reply AS A
INNER JOIN HR_CALLCENTER.dbo.question AS B ON A.questionId = B.questionId
INNER JOIN HR_CALLCENTER.dbo.users AS C ON B.createdId = C.employeeId
INNER JOIN HR_CALLCENTER.dbo.users AS D ON A.createdId = D.employeeId
WHERE A.replyId = 3