Shawn, partially discourage but mostly confused about
what I really need to do.
Bear in mind for a moment, that I'm working in a
somewhat untradional manner. Meaning a) very new to
database and SQL b) (and i realize this list is not
for programming languages) using a RAD that allows me
to point, click and insert , where it's magically
transformed into code.
So back to what I'm trying to accomplish. I want a
way for the user to be allowed to choose from what
point in the timeline records will be returned in a
search. i.e. from 30 days or less, 15 days or less, 2
days or less, etc.
Now, if I run this query against the
select EntryDate from EntryTable
where Date_Sub(Curdate(), interval 2 day) <= EntryDate
life is good. I get the records returned just the way
I want. They key though is the 2 (after interval) as
I want that number to be a variable.
That is why I created the table that has values of 1,
2 , 15, 30, etc). I thought if I could use those
values, in either a case statement (probably not with
4.0.20) or an "if statement" , well magic would happen
I hope I explained it better this time.
Apologies for the confusion.
--- SGreen@stripped wrote:
> Were you able to solve you problem another way or
> just discouraged by my
> response? I wasn't trying to make you feel bad, you
> just covered so much
> ground in your original post that I really couldn't
> understand your issue.
> Please, post again but with a little more
> We all want to help but we aren't there looking over
> your shoulder so we
> can't see everything you see. We just need a little
> help to visualize your
> problem, OK?
> Shawn Green
> Database Administrator
> Unimin Corporation - Spruce Pine
> Stuart Felenstein <stuart4m@stripped> wrote on
> 09/13/2004 11:09:59 AM:
> > Ok, never mind . I guess a conditional loop is
> > needed.
> > Stuart