database.py: Uses bulk queries and inserts for URL strings.