DMF for water treatment