Similar Items: Multiset semantics in SPARQL, Relational Algebra and Datalog