473,503 Members | 2,142 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Inserting expression into a query

Hi

I am using a form field as criteria in a query like this
[Forms]![MyForm]![MyField]. This works fine if the field has a single value
like "value1" but if the field has an expression as a value like "value1 or
value2" then the query returns nothing. Is there a way to insert the literal
value of the field "value1 or value2" into the query? I want to do it in a
way that I can change this expression at runtime.

Thanks

Regards
Nov 12 '05 #1
1 1502
Answered in the sponsored newsgroups. If you feel _compelled_ to post the
same question to multiple newsgroups, please crosspost so the answers will
show up in the newsgroup with the copies of the question. This one was
_multiposted_ separately, so there is no link from that answer to the
question here.

"John" <Jo**@nospam.infovis.co.uk> wrote in message
news:40***********************@news-text.dial.pipex.com...
Hi

I am using a form field as criteria in a query like this
[Forms]![MyForm]![MyField]. This works fine if the field has a single value like "value1" but if the field has an expression as a value like "value1 or value2" then the query returns nothing. Is there a way to insert the literal value of the field "value1 or value2" into the query? I want to do it in a
way that I can change this expression at runtime.

Thanks

Regards

Nov 12 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

39
7843
by: | last post by:
I am trying to run the following agregate function in a parameterized query on Access2000: Min(.*sqr(./.)/) The query saved OK, but an attempt to run it results in the message: The expression...
29
2477
by: shank | last post by:
1) I'm getting this error: Syntax error (missing operator) in query expression on the below statement. Can I get some advice. 2) I searched ASPFAQ and came up blank. Where can find the "rules"...
1
1080
by: bockley | last post by:
I am having trouble inserting two queries...I am trying to insert an new item(pk) into a table in one query, and then inserting an item(fk) in another table that relates to the other item just...
2
17008
by: Darren | last post by:
Hi All, This will probably have the easiest solution but as I'm still a newbie and need some help... When building a query I would like to create a field called Name which includes both the...
1
314
by: John | last post by:
Hi I am using a form field as criteria in a query like this !!. This works fine if the field has a single value like "value1" but if the field has an expression as a value like "value1 or...
2
7315
by: Mike Turco | last post by:
I like using the expression builder for a lot of different things but it isn't always available when I want to use it, for example in the code window, or in all of the control properties. I am...
1
3705
by: ing42 | last post by:
I have a problem with inserting records into table when an indexed view is based on it. Table has text field (without it there is no problem, but I need it). Here is a sample code: USE test GO...
7
6863
by: John Øllgård Jensen | last post by:
Hi Using MS Asccess 2000: In a query I'm trying to create a new field with following expression: FilmDate: Left(,4) The field "FilmNo" is another text field in the query. This is...
28
16350
by: Marc Gravell | last post by:
In Linq, you can apparently get a meaningful body from and expression's .ToString(); random question - does anybody know if linq also includes a parser? It just seemed it might be a handy way to...
3
3510
by: mbardwel | last post by:
I am building a query in Access 2003. Here is my problem. I create an expression called SUN_ST In a later expression I reference a calculation based on SUN_ST ie, MON_ST=sum-SUN_ST SUN_ST is...
0
7287
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7349
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
7008
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5594
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5022
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4688
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
1521
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
746
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
399
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.