using data from database in d3