Delete false data from mysql feed


i have a selfhosted install of emoncms and happy about it

but false data has entered some of the feeds, they are easy to find as i just have to search for data values that are past 80


they come from an ill configured device that sends data in to 6 feeds,

how can i delete data from all 6 feeds when i have the time stamp from the first feed?

You would be better deleting the feeds from the UI. If you only want to delete the data, you can do so from the same UI interface.

Or do you just want to delete a couple of data points?

i tried to delte from the UI but when i click on the feed nothing comes up

its a little more than “a couple”


and i need to delete the same amount in feed_8 to feed_12

and all i have to go after is the time stamp from feed_7

select the checkbox. then a dustbin icon will appear at the top.

If he does that, won’t it zap the entire feed?
He indicated that he wanted to zap values “past 80.”
Not sure, but it sounds like he’s after zapping feeds with values greater than 80 in them.


15768 data points in each feed to find and delete

is there not an sql command that can do it? ie from phpmyadmin


Possibly but I don’t know.

No, you can trim data using the same UI.

1 Like

Yes, it looks like this:

DELETE FROM table_name
WHERE condition;

OK. Good to know. Tnx!

Except I’d not noticed these are SQL feeds though it does say that in the title :man_facepalming:

yes but its only in the first feed i know the condition and i allready have that

SELECT * FROM feed_7 WHERE data > 80

for the others the condition is the timestamp found in the first condition


i opted to use SQL on my selfhosting(hosted at as they have unlimited database space and they said i could post data as crazy i wanted

so i have several devices that send 6 streams of data at 10 sec interval

What you need to do is get the timestamp of the first condition and add it to the query.
The result will be similar to:

SELECT * FROM feed_7 WHERE data > 80 and timestamp = TIMESTAMP

where TIMESTAMP is the actual timestamp in the first condition.

Are we dealing with a single timestamp in the first condition, or multiple timestamp values?

and that is in each of the 6 feeds


If you know the range of the timestamps in the first condition, you can specify that range
as the second condition.

e.g. SELECT * FROM feed_7 WHERE data > 80 and timestamp > xxxxxx and timestamp < yyyyyy

the pic is of the first data point in the first feed table

Do ALL of the rows you want to zap contain data > 80 ?

no, that is why i’m asking

feed_7 is the only one where i can use that condition

for feed_8 to feed_12 i have to delete with the time value found in feed_7