MySQL Lists are EOL. Please join:

List:General Discussion« Previous MessageNext Message »
From:John Hicks Date:April 23 2006 8:57pm
Subject:Re: If exists query.
View as plain text  
Paul Halliday wrote:
> I am trying to formulate a query that will increment if a condition is true.
> For example, if I do a select (just let me know if there was data on
> this day, if so increment count by 1 and check the next day) where
> timestamp between jan and feb.

Could you be a bit more specific?

Where do you want to store the count?

What do you mean by "if there was data on this day"? Does the design of 
the table anticipate no more than one record per day? Does each record 
correspond to a single day?

If exists query.Paul Halliday21 Apr
  • Re: If exists query.John Hicks23 Apr
    • Re: If exists query.Paul Halliday23 Apr
Re: If exists query.Paul Halliday24 Apr
  • Re: If exists query.Shawn Green24 Apr
  • Re: If exists query.Peter Brawley24 Apr