Hello,
The val() seems to work (Csng() also works) - but what neither of those do is become useful for me other than visually in my first step. Let me explain.
This is my SQL statement:
SELECT TEST_Surveys.SurveyID, IIf([quest1]="N/A",Null,Val([quest1])) AS Q1, IIf([quest2]="N/A",Null,Val([quest2])) AS Q2, IIf([quest3]="N/A",Null,Val([quest3])) AS Q3, IIf([quest4]="N/A",Null,Val([quest4])) AS Q4, IIf([quest5]="N/A",Null,Val([quest5])) AS Q5, IIf([quest6]="N/A",Null,Val([quest6])) AS Q6, IIf([quest7]="N/A",Null,Val([quest7])) AS Q7, IIf([quest8]="N/A",Null,Val([quest8])) AS Q8, IIf([quest9]="N/A",Null,Val([quest9])) AS Q9, IIf([quest10]="N/A",Null,Val([quest10])) AS Q10
FROM TEST_Surveys
GROUP BY TEST_Surveys.SurveyID, IIf([quest1]="N/A",Null,Val([quest1])), IIf([quest2]="N/A",Null,Val([quest2])), IIf([quest3]="N/A",Null,Val([quest3])), IIf([quest4]="N/A",Null,Val([quest4])), IIf([quest5]="N/A",Null,Val([quest5])), IIf([quest6]="N/A",Null,Val([quest6])), IIf([quest7]="N/A",Null,Val([quest7])), IIf([quest8]="N/A",Null,Val([quest8])), IIf([quest9]="N/A",Null,Val([quest9])), IIf([quest10]="N/A",Null,Val([quest10]));
This is what it returns
# Q1 Q2 Q3 Q4 Q5 Q6 Q7 Q8 Q9 Q10
1 1 1 0 1 1 0 1 0 1
2 1 1 1 1 1 1 1 1 1
3 0 1 1 1 1 1 1 1 1 1
4 1 0
5 1 1 1 1 1 1 1 1 1 1
The issue is that I now try and sum up questions 1-10 (Q1+Q2...) - but it only gives me a number for question 3 and question 5. The rest of them are null - I'm assuming this is because I have a null value?
What I want to do with these scores now is:
Assign each question a set number of points or % of total. If the question is null, it then assigns that null questions value evenly across all of the questions that aren't null.
Granted - that's probably outside of what I'm able to do quickly - but I'm sure I could figure it out.....I've put some time into getting these numbers to add up and I can't - which is starting to get frustrating.....am I doing something wrong????
:-/
Lisa