try this query as
SELECT distinct
userid,
fullname,
lastname,
firstname,
localjobtitle,
employmentstatusid,
dateofjoining,
dateofexit,
siteid,
email,
topfunctionid,
active,
exitingthecompany,
lmsroleid,
locallanguagejobtitle into TestTable
FROM
tblUserProfile,
tblreportingto ,
tblCountry