Public
Edited
Jul 9
Fork of DuckDB demo
Insert cell
Insert cell
reviewData = [{"username": 3, "review": "I love this meeting"}, {"username": 5, "review": "This meeting never starts on time"}, {"username" : 17, "review": "The people here are wonderful, but the coffee isn't very good"}]
Insert cell
Insert cell
fluviusData = fluviusDataRaw
Insert cell
Insert cell
client
SELECT column00, "Meeting Name", Day, "Start Time", review
FROM meetings
LEFT OUTER JOIN reviews ON meetings.column00 = reviews.username
ORDER BY column00;
Insert cell
client = DuckDBClient.of({
meetings: FileAttachment("my_aadata-2.csv"),
reviews: reviewData,
fluv: fluviusmaand1,
prijs: belpex_2425
})
Insert cell
FluviusMaand1@1.csv
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
client
SELECT *
FROM reviews;
Insert cell
client
SELECT *
FROM meetings
WHERE Day = 'Wednesdays';
Insert cell
Insert cell
Insert cell
client
SELECT DISTINCT Latitiude, Longitude
FROM meetings;
Insert cell
client
Insert cell
Insert cell
wednesdays
Insert cell
client
SELECT DISTINCT "Street Address"
FROM meetings;
Insert cell
belpex_2425
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
belpex_2425
select year(a.Datum) Jaar, month(Datum) maand, day(Datum) dag, prijs from belpex_2425 a
Insert cell
client
show tables
Insert cell
Insert cell
Insert cell
ggg = alasql(
"select d.* , minrow.Prijs as minprijsdag, d.Prijs - minrow.Prijs as verschil from ? as d join (select Datum,Prijs from ? d2 where Prijs in (select min(Prijs) from ? as x where x.Datum = d2.Datum )) as minrow on d.Datum = minrow.Datum",
[belpex_2425c, belpex_2425c, belpex_2425c]
)
Insert cell
Min = alasql("select * from ? where Prijs < -140", [belpex_2425c])
Insert cell
alasql = require("alasql")
Insert cell
BelPex_2425C.csv
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
client
SELECT *
FROM meetings
WHERE Day = 'Wednesdays';
Insert cell
Insert cell
belpex_2425
select d.* , (select MIN (Prijs) from belpex_2425 d2 where d2.datum = d.datum ) as minprijs from belpex_2425 d
Insert cell
belpex_2425
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
client
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
workbook = FileAttachment("FluviusMaand.xlsx").xlsx()
Insert cell
import { sql } from "@observablehq/sql" // Let op: dit is de
Insert cell
belpex_2425
select DAY(Datum),count(*) from belpex_2425 group by day(Datum)
union
select month(Datum),count(*) from belpex_2425 group by month(Datum)
union
select year(Datum),count(*) from belpex_2425 group by year(Datum)
Insert cell
workbook.sheetNames
Insert cell
data = workbook.sheet(0, {
headers: false,
// range: "A1:J10"
})
Insert cell
data
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
client
select * from fluv
Insert cell
vol = 200
Insert cell
// Cell: `filteredFluviusData`
fluvFilt = {
return client.sql`
SELECT *
FROM fluv
WHERE "Volume" > ${vol} -- Let op de dubbele aanhalingstekens om "EAN-code"
`;
}
Insert cell
fluvFilt
Insert cell
BelPex_2425C.csv
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
FluviusMaand1.csv
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell

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.
Learn more