From Datalog to Sequence Datalog: Languages and Techniques for Querying Sequence Databases