?
Solved

IIf query syntax in Make table query

Posted on 2013-02-03
2
Medium Priority
?
294 Views
Last Modified: 2013-02-03
I am getting a error with the following make table query,

BaseCost: IIf([Weight]<100,[Cost]),IIf([Weight]>100,[Cost]*[Weight])

Error: "contains invalid syntax or you need to enclose your text data in quotes"

If i try the first part only it works, BaseCost: IIf([Weight]<100,[Cost])
0
Comment
Question by:ExpressMan1
[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
2 Comments
 
LVL 34

Accepted Solution

by:
Norie earned 2000 total points
ID: 38849632
You have an unneeded  ) after [Cost].

I don't think the 2nd IIf is needed, so try this.

BaseCost: IIf([Weight]<100,[Cost],[Cost]*[Weight])
0
 

Author Closing Comment

by:ExpressMan1
ID: 38849698
Perfect. Thank You imnorie.
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

This article helps those who get the 0xc004d307 error when trying to rearm (reset the license) Office 2013 in a Virtual Desktop Infrastructure (VDI) and/or those trying to prep the master image for Microsoft Key Management (KMS) activation. (i.e.- C…
Microsoft Access is a place to store data within tables and represent this stored data using multiple database objects such as in form of macros, forms, reports, etc. After a MS Access database is created there is need to improve the performance and…
The viewer will learn how to create two correlated normally distributed random variables in Excel, use a normal distribution to simulate the return on different levels of investment in each of the two funds over a period of ten years, and, create a …
Learn how to make your own table of contents in Microsoft Word using paragraph styles and the automatic table of contents tool. We'll be using the paragraph styles in Word’s Home toolbar to help you create a table of contents. Type out your initial …

762 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