Push Email at Midnight **solved**

All about the standard Meteobridge devices based on mobile routers from TP-Link, D-Link, ASUS

Moderator: Mattk

Post Reply
david.delano
Senior Boarder
Senior Boarder
Posts: 47
Joined: Thu May 16, 2013 6:39 am

Push Email at Midnight **solved**

Post by david.delano »

I am trying to set up a push email that at midnight will give me the accumulated rain total for the (previous) day. It looks like part of the problem is that 0000 is considered the next day, and thus there is no data or it is 0. However, the email I receive is a bit strange:

Total rainfall at midnight is [rain0total-sumday=in.2] inch(es).

That is also the string I have in the push email settings. If I use this same string at any other time setting, I get the actual rain total data, even if it's 0.

So, two questions.....why is [rain0total-sumday=in.2] not resolving at midnight? And, is there a better way to dump the data for the previous day?

Just a note....dumping the data at 11:45pm would not be good if it is raining at the time. I need the data to be more complete.

Thanks for any help,
David
User avatar
wvdkuil
Platinum Boarder
Platinum Boarder
Posts: 606
Joined: Sun Jul 24, 2011 8:00 pm
Location: Belgium
Contact:

Re: Push Email at Midnight

Post by wvdkuil »

david.delano wrote:I am trying to set up a push email that at midnight will give me the accumulated rain total for the (previous) day. It looks like part of the problem is that 0000 is considered the next day, and thus there is no data or it is 0. However, the email I receive is a bit strange:

Total rainfall at midnight is [rain0total-sumday=in.2] inch(es).

That is also the string I have in the push email settings. If I use this same string at any other time setting, I get the actual rain total data, even if it's 0.

So, two questions.....why is [rain0total-sumday=in.2] not resolving at midnight? And, is there a better way to dump the data for the previous day?

Just a note....dumping the data at 11:45pm would not be good if it is raining at the time. I need the data to be more complete.

Thanks for any help,
David
I think that sending the e-mail at 00:05 and asking for yesterdays value would solve your problem more securely.
Does not make any difference if the mail is a few minutes late, as yesterday values remain the same for the whole day.
I use [rain0total-ydaysum.1:0] for that.
Wim
david.delano
Senior Boarder
Senior Boarder
Posts: 47
Joined: Thu May 16, 2013 6:39 am

Re: Push Email at Midnight

Post by david.delano »

Thanks!

This is what I was looking for. Also, I don't really need the email to come out at midnight. I also have an email coming out at 0700 and I can just add this data to it. Pulling the previous day data is what I was looking for.
david.delano
Senior Boarder
Senior Boarder
Posts: 47
Joined: Thu May 16, 2013 6:39 am

Re: Push Email at Midnight

Post by david.delano »

How do I mark this as answered??
User avatar
wvdkuil
Platinum Boarder
Platinum Boarder
Posts: 606
Joined: Sun Jul 24, 2011 8:00 pm
Location: Belgium
Contact:

Re: Push Email at Midnight

Post by wvdkuil »

david.delano wrote:How do I mark this as answered??
You can edit your first message and edit the subject with any extra words you like.
Wim
User avatar
admin
Platinum Boarder
Platinum Boarder
Posts: 7874
Joined: Mon Oct 01, 2007 10:51 pm

Re: Push Email at Midnight **solved**

Post by admin »

david.delano wrote:However, the email I receive is a bit strange: Total rainfall at midnight is [rain0total-sumday=in.2] inch(es).
When a set of data is not there, the variable statement is not evaluated. At 0:00 no data for the new day might be there.
you can define a default string to be returned instead by adding a ":" phrase like "[rain0total-sumday=in.2:0.00]" which will return 0.00 when there is no rain data for the specified time frame available.
david.delano
Senior Boarder
Senior Boarder
Posts: 47
Joined: Thu May 16, 2013 6:39 am

Re: Push Email at Midnight **solved**

Post by david.delano »

Here is what I ended up using. This message is scheduled for 0700.

Rainfall Total for [MM]/[DD]/[YYYY] at [hh][mm]#Report for [MM]/[DD]/[YYYY]\n\nTotal rainfall at [hh][mm] is [rain0total-daysum=in.2:0.00] inch(es).\n\nTotal rainfall yesterday was [rain0total-ydaysum=in.2:0.00] inch(es).
glennpm
Senior Boarder
Senior Boarder
Posts: 54
Joined: Sun Aug 03, 2014 8:47 pm

Re: Push Email at Midnight

Post by glennpm »

Hi,

I have had the same issue and changed my "yesterday" reporting to be run at 00:15. Is there a way to override the drop down value so that I could for example, run the report at 00:01? I noticed that 00:05 is mentioned in the quote below and this is not a drop down value.

Thanks

David[/quote]I think that sending the e-mail at 00:05 and asking for yesterdays value would solve your problem more securely.
Does not make any difference if the mail is a few minutes late, as yesterday values remain the same for the whole day.
I use [rain0total-ydaysum.1:0] for that.
Wim[/quote]
User avatar
admin
Platinum Boarder
Platinum Boarder
Posts: 7874
Joined: Mon Oct 01, 2007 10:51 pm

Re: Push Email at Midnight

Post by admin »

glennpm wrote:Is there a way to override the drop down value so that I could for example, run the report at 00:01?
No, no way.
Post Reply