DRW date Default Value

G

Guest

FP2002 web with Access 2002 DB

I have a DBR section that displays results based on 2 drop down criteria
fields - a text field and a date field. I'm having trouble setting an "all"
default value for the date field. I've tried the % and "1 OR 1" but neither
worked.

Can you please tell me the syntax to use to set an all values default value
for the date field which is used as a criteria for the Database Results
displayed? I've searched for the proper syntax to use but have not been able
to find the solution.
 
K

Kathleen Anderson [MVP - FrontPage]

G

Guest

Maureen,
I had the same problem with a number field (instead of a date field). I
tried removing the apostrophes :):number:: instead of '::number::'), using
the number sign # instead, but nothing worked. Somewhere on the microsoft
site I read that you can only use the LIKE % to compare it with a text field
not a number or date field.

In the end I solved it by redefining the number field in my Access database
as a text field. However I did have to rerun the DBRW after that. Good luck!

Margot
 
G

Guest

Thanks again Kathleen for good direction. I had seen this article before but
wasn't reading it correctly until now...at least I think I've read it
correctly this time. I made the change described in the KB article - ost of
the code follows:

s-sql="SELECT * FROM tblSchdScores WHERE (Division LIKE '%::Division::%' AND
Dte = #::Dte::#) ORDER BY Dte ASC,GTime ASC,Division ASC"

I have the default values set to % in the DBR drop down box named DTE that
serves as the criteria submitted via a form above the DBR area

Database Results Error
Unable to find operator in query string. Query string currently is SELECT *
FROM tblSchdScores WHERE (Division LIKE ? AND Dte = #::Dte::#) ORDER BY Dte
ASC,GTime ASC,Division ASC

Can you offer any further direction to assist me in this? THANKS VERY MUCH!

Unfortunatley, I'm getting the following error message in the DBR area when
I try to let the default value of % pass with the DTE field (If I select a
valid date from the drop down list it works, but I can't get the option of
select all = % to work).
 
K

Kathleen Anderson [MVP - FrontPage]

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

DBR field as default value on form 3
Parameter in DBR 6
Form Auto Submit? 1
Form field value passed 1
DRW 4
DBR Fails for some 2
DBR Form 1
DBR Dropw Down Search Retains selection after submit 2

Top