Query search on numbers headache

P

Paul Milner

Hi
I have set up a query in frontpage with a search form.
In the database there is a field called
sponsorship_amount the records in the field are

Under 10,000
Under 20,000
upto in increments to
under 500,000

I wish to search for amounts of say Under 300,000 and
have records of the amount below this ie 200,000 40,000
etc.
I can do a search with this SQL

AND Amount_required <= '::Amount_required::')

upto 99,000 but as soon as I go over 100,000 it seams to
treat it as 10,000 and returns records under 10,000
How can I change this
Paul M
 
T

Thomas A. Rowe

Is the database field type set to numerical?

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WEBMASTER Resources(tm)

FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
 
P

Paul Milner

Thanks for replying
The field is a text field if I change field to number
then I can't put the word Upto before the number ie Upto
30,000
I dont know if this is good practice or not or should I
not mix number and letters
Paul M
 
T

Thomas A. Rowe

If you want to search numbers, then the field must be numerical, otherwise a text field will
list/sort numbers in the follow order:

1
10
100
1000
10000
2
20
200
2000

etc.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WEBMASTER Resources(tm)

FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
 
P

Paul milner

I have tried it and it works
But is there a way of including the commas ie 300,000
in the results and if it's not to dificult is there away
of adding the word Upto or £ before the number.
Thanks
Paul N
-----Original Message-----
If you want to search numbers, then the field must be
numerical, otherwise a text field will
 
T

Thomas A. Rowe

See

http://www.mikecaldwell.com/VBINDEX/formatnumber.html

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WEBMASTER Resources(tm)

FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================


I have tried it and it works
But is there a way of including the commas ie 300,000
in the results and if it's not to dificult is there away
of adding the word Upto or £ before the number.
Thanks
Paul N
-----Original Message-----
If you want to search numbers, then the field must be
numerical, otherwise a text field will
 

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

Top