Solved

Access 2003 expression

Posted on 2013-12-12
9
411 Views
Last Modified: 2013-12-13
Below is the expression I am trying to use in a query however when I try to save the query it says I have entered an operand before an operator.  The BOM is the table the two fields are in brackets.  Any ideas???  Thanks



Expr1: 3600/ BOM [STD_CYCLE] * BOM [CAVITIES]
0
Comment
Question by:submarinerssbn731
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
  • 2
9 Comments
 
LVL 40

Assisted Solution

by:Vadim Rapp
Vadim Rapp earned 250 total points
ID: 39715011
there must be a dot between table and field name.

3600/ BOM.[STD_CYCLE] * BOM.[CAVITIES]
0
 

Author Comment

by:submarinerssbn731
ID: 39715027
I put the dots in and then it removes the brackets and then gives me an error stating you tried to execute a query that does not include the specified expression '3600/BOM.STD_CYCLE*BOM.CAVITIES as part of an aggregate function.
0
 
LVL 21

Accepted Solution

by:
Boyd (HiTechCoach) Trimmell, Microsoft Access MVP earned 250 total points
ID: 39715095
Is the table BOM included in the From clause of the SQL? Or put another way. have you added the table BOM to the query?

Note: Not adding ( and ) the calculation will be the same as:

(3600 / BOM.[STD_CYCLE]) * BOM.[CAVITIES] 

Open in new window


Is that what you want?
0
Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

 

Author Comment

by:submarinerssbn731
ID: 39715105
It is not a SQL query statement but an Access 2003 query in design view.
0
 

Author Comment

by:submarinerssbn731
ID: 39715133
I've requested that this question be closed as follows:

Accepted answer: 0 points for submarinerssbn731's comment #a39715105

for the following reason:

Finally got it to run!  Thanks so much!  Excellent Expert!!!
0
 
LVL 40

Expert Comment

by:Vadim Rapp
ID: 39715126
That it does not include the expression as part of an aggregate function is different problem. If your query has GROUP BY, every expression has to be either in aggregate, or in GROUP BY. For more information, search the web for "does not include as aggregate function", or post separate question.
0
 
LVL 40

Expert Comment

by:Vadim Rapp
ID: 39715134
The initial problem was resolved by comment ID: 39715011
0
 

Author Closing Comment

by:submarinerssbn731
ID: 39716614
Great answers!!!   Thanks!!!
0
 
LVL 21
ID: 39717720
It is not a SQL query statement but an Access 2003 query in design view.

FYI: The Access query designer is just a GUI view of the SQL statement you are creating. The Query Designer view is a great to. Note that not all possible SQL statement can be displayed in Design view. There are times when you must switch to SQL view and write the SQL statement manually.
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
Did you know that more than 4 billion data records have been recorded as lost or stolen since 2013? It was a staggering number brought to our attention during last week’s ManageEngine webinar, where attendees received a comprehensive look at the ma…
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question