cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

DeleteStreamEntry service not work in Thingworx 9.0.4

LL_9777686
4-Participant

DeleteStreamEntry service not work in Thingworx 9.0.4

Hi team,

 

I tried to delete entry using built-in service DeleteStreamEntry given the entry id, but it looks like this service did not delete successfully, the entry is still there. Is this an issue or any workaround to resolve this problem?

 

a.PNG

 

Thanks.

1 ACCEPTED SOLUTION

Accepted Solutions

Hello @LL_9777686 ,

You may want to try snippet like below.

for (var x = 0; x < tableLength; x++) {
	var row = streamEntriesForUser.rows[x];
	logger.info("streamEntriesForUser Rows :: " + row.id);
	Things["<Name_of_Your_Stream_Entity>"].DeleteStreamEntry({
		streamEntryId: row.id /* STRING */
	});
}

We wrote this snippet in TWX 8.5.3 and recently upgraded to TWX 9.2.1 and it works absolutely fine in both the environment. 

 

I am sure it will work for you with little modifications.

 

Regards,

Shirish

View solution in original post

2 REPLIES 2

Hello @LL_9777686 ,

You may want to try snippet like below.

for (var x = 0; x < tableLength; x++) {
	var row = streamEntriesForUser.rows[x];
	logger.info("streamEntriesForUser Rows :: " + row.id);
	Things["<Name_of_Your_Stream_Entity>"].DeleteStreamEntry({
		streamEntryId: row.id /* STRING */
	});
}

We wrote this snippet in TWX 8.5.3 and recently upgraded to TWX 9.2.1 and it works absolutely fine in both the environment. 

 

I am sure it will work for you with little modifications.

 

Regards,

Shirish

slangley
23-Emerald II
(To:LL_9777686)

Hi @LL_9777686

 

If you found that the previous response was helpful, please mark it as the Accepted Solution for the benefit of others with the same question.

 

Regards.

 

--Sharon

Top Tags