db.query(`select location, date, weather from weather where location='${location}' limit 20`)
// As an alternative to the above approach using ${} within the template literal, you can also pass an array of variables as a second arg to the DatabseClient.query() method.
// This version will do any needed escaping if your variable has any tricky characters like quotes (‘“) in it. See https://observablehq.com/@observablehq/connecting-to-databases#query for more details!
db.query('select location, date, weather from weather where location=$1 limit 20',[location])
viewoflocation=select(['Seattle','New York'])
Purpose-built for displays of data
Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.