Datalog is a query language, but I haven't found good libraries for the "connector" pieces of translating prolog/datalog predicates to SQL, constructing or syncing schema definitions, and database migrations. It seems like if you want to use Datalog, Datomic is the best option. (But datomic is sort of pricey for commercial use relative to SQL databases like Postgresql.)