You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
324 B

const express = require('express');
const app = express();
const pg = require('pg');
const client = new pg.Client({
database:"outcomes_tracker"
})
app.get('/instances', async (req, res)=>{
const instances = await client.query('SELECT * FROM instances');
res.json(instances.rows);
})
client.connect();
app.listen(3000);