P
ptr1967
Guest
I am mostly familiar with Oracle syntax and am now dealing with a need to rewrite a portion of sql into MS Access.
I have 4 tables where there may be no data in just 1 of the 4 tables - "skill_assessments" if a user has not provided any data for that question category yet. Every other table/columns has a simple join.
I need to list all rows including the nulls with something like "N/A" if the user's record has no data for it. I definitely got spoiled using the (+) syntax and now feel like a beginner again. If anyone can assist in pointing me in the correct direction Thanks in advance.
SQL - as in Oracle...
SELECT
sa.skillID,
nvl(sa.skill_level_score, 'n/a') AS skill_level_score,
sa.skill_level_score,
s.skilltype,
s.skillname,
tsr.requirement_level
FROM
skills s,
skill_assessments sa,
trades t,
trade_skillrequirement tsr
WHERE sa.userPK = 1
AND s.skilltype = sa.skilltype (+)
AND s.skilltype = tsr.skilltype
AND t.tradePK = tsr.tradePK
AND t.tradepk = 9
ORDER BY s.skilltype ASC
I have 4 tables where there may be no data in just 1 of the 4 tables - "skill_assessments" if a user has not provided any data for that question category yet. Every other table/columns has a simple join.
I need to list all rows including the nulls with something like "N/A" if the user's record has no data for it. I definitely got spoiled using the (+) syntax and now feel like a beginner again. If anyone can assist in pointing me in the correct direction Thanks in advance.
SQL - as in Oracle...
SELECT
sa.skillID,
nvl(sa.skill_level_score, 'n/a') AS skill_level_score,
sa.skill_level_score,
s.skilltype,
s.skillname,
tsr.requirement_level
FROM
skills s,
skill_assessments sa,
trades t,
trade_skillrequirement tsr
WHERE sa.userPK = 1
AND s.skilltype = sa.skilltype (+)
AND s.skilltype = tsr.skilltype
AND t.tradePK = tsr.tradePK
AND t.tradepk = 9
ORDER BY s.skilltype ASC