I'd have to experiment more, but I believe that if I kept the filename static each iteration of Replace would simply write over the previous tweet so that only one tweet was ever being stored to the db. Only by changing the name was I able to add multiple tweets with Replace. (I think.)
But, I thought there were 99 ways to skin a cat? ;)
I only selected BaseX to learn XQuery.
On 2020-02-04 4:17 a.m., Christian GrĂ¼n wrote:
The filename is arbitrary, you can choose it as you like.
A general note: Your code may get easier again if you write more code in XQuery. But there are always (I think it was) 42 ways to solve a single problem.