Linking criteria to query from combox box.

  • Thread starter Sianboy via AccessMonster.com
  • Start date
S

Sianboy via AccessMonster.com

Hey All I need help on this query.

There is a combobox displaying different Car CC like "<661cc", "661cc -
1600cc" and ">3000cc". I aware I need to convert the non numeric text to
numeric expressions before linking the criteria to the query itself. However,
I have tried using multiple column box on this search criteria but could not
do it as the access seemed to forbid signs like "<", ">" or "And" to the
query itself.

Anyone who know how to do it I will appreciate your help. Thanks!
 
K

KARL DEWEY

Those are logic operations and will not work from within a text string.
You need to either put them into the query SQL or design view.
 
K

KARL DEWEY

See mine and others post -- New Users (Getting Started) - Changing the
criterion in a Query.
 
S

Sianboy via AccessMonster.com

Ok sure thanks a lot! I will read thru it and try it out.

KARL said:
See mine and others post -- New Users (Getting Started) - Changing the
criterion in a Query.
Those are logic operations and will not work from within a text string.
You need to either put them into the query SQL or design view.
[quoted text clipped - 9 lines]
 
K

KARL DEWEY

You need the GROUP BY ---
SELECT tWhiteSpaceMatrixData.SundyneComp, tWhiteSpaceMatrixData.SundynePump,
tWhiteSpaceMatrixData.Sunflo, tWhiteSpaceMatrixData.MasoSine,
tWhiteSpaceMatrixData.Ansimag, tWhiteSpaceMatrixData.HMDKontro,
tWhiteSpaceMatrixData.Marelli,
Sum(IIf(Nz([SundyneComp],0)="N/A",0,1)+IIf(Nz([SundynePump],0)="N/A",0,1)+IIF(Nz([Sunflo],0)="N/A",0,1)+IIf(Nz([Ansimag],0)="N/A",0,1)+IIf(Nz([HMDKontro],0
="N/A",0,1)+IIf(Nz([MasoSine],0)="N/A",0,1)+IIf(Nz([Marelli],0)="N/A",0,1))
AS AvailableSpaces
FROM tWhiteSpaceMatrixData
GROUP BY tWhiteSpaceMatrixData.SundyneComp,
tWhiteSpaceMatrixData.SundynePump, tWhiteSpaceMatrixData.Sunflo,
tWhiteSpaceMatrixData.MasoSine, tWhiteSpaceMatrixData.Ansimag,
tWhiteSpaceMatrixData.HMDKontro, tWhiteSpaceMatrixData.Marelli;
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top