Fixed values in queries

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I am trying to create a fixed file, that I would like to export out of
Access. I have created a query, but some of the fields in the query require a
default value.
Can anyone tell me how to do this?

Thanks so much.
 
Lucy,

Open the table the query is bound to in design view.

On the properties for the fields their is a 'Default Value' selection.
Enter the value there and it will be included in the query.

hth

Gary
 
In the query wizard for the field that requires a default you can try
this:

iif(isnull([tblName]![FieldName]),"Default
Value",[tblName]![FieldName])


note:
1) it is i i f not i f
2) for a numeric value you do not use the quotes.
3) The test can be any type of test that you want. First falue after
test is if it is true and the second is what is used if it is false.

Ron
 
Thanks Gary. I am pulling data into the tables from a database and I am
wanting to add default values in the query and not in the tables. Is there a
way to do this in a query?
 
Back
Top