473,327 Members | 2,012 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,327 software developers and data experts.

Syntax error (comma) in query expression

I am creating a Query in design view and I am try to create a calculated field with an IIf conditional Logic.

Increase:IIf([YearsService]>9,[Salary]*0.03,[Salary]*0.02)

The fields YearsService and Salary is part of my query.

Is a very simple query but it does not run.
Mar 23 '17 #1
1 1720
PhilOfWalton
1,430 Expert 1GB
You might try

Expand|Select|Wrap|Line Numbers
  1. Increase:IIf(Nz([YearsService]) > 9, [Salary]*0.03, [Salary]*0.02)
  2.  
Could be getting a null YearsService

Phil
Mar 23 '17 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Raphael Gluck | last post by:
Hi everyone I have a page on my site in which i wish to display links to brochures, and i have stored an index of these links in my database. however when i pass from the master page,...
1
by: Rolan | last post by:
I created a function module base on a query to provide a group record total for a subform and which is posted to a field on the main form. Everything seems to work fine except that I consistently...
8
by: Dalan | last post by:
Please help - just take a quick look at the function code below. It probably just needs some minor tweaking. The function module is based on an intermediate query to provide a group record...
1
by: maneeshkhare | last post by:
I am trying to update a field in Access db (.mdb) via a DataSet using the following code. I am continously getting this error: Has anybody seen this before? 1. If I try using the same code for...
1
by: amitbadgi | last post by:
I am geting the following error while conv an asp to asp.net Exception Details: System.Runtime.InteropServices.COMException: Syntax error in query expression 'id =System.__ComObject'. Source...
2
by: Tom Baxter | last post by:
I have a numeric column in a query called Prov1.Volume. When I try taking the sum of that column (using SUM aggregate function in Design View) it gives a syntax error. It says that...
4
by: veer | last post by:
Hi i am running a date query squery = "Insert into " & txttablename & " IN '" & txtdatabase & " ' select * from " & sTableName & " IN '" & txtfolderpath & "\" & sArrFolder(icount) & "\" &...
5
by: OzNet | last post by:
Can someone tell me what I am doing wrong here please? I have a form with two unbound text boxes formatted to short date and an OK button. My button code is as follows: Private Sub...
6
by: D Rid | last post by:
here is my SQL statement: SELECT . , .* , .* FROM ( INNER JOIN ON . = CDBL(])) INNER JOIN
1
by: Vasago | last post by:
I have narrowed it down to .Driver) =" & Me!. My employees do have a comma in their names. Thank you for your help. Error Code says: Run-time error '3075' Syntax error(comma) in query...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.