Query editor
/* Success! If you're still running into issues, check out https://dune.com/docs/query/syntax-differences/ or reach out in the #dune-sql Discord channel. */SELECTeth.day,(eth.count + renew.count - released.count) AS ".eth total growth",eth.count AS ".eth name registered",eth.owner_count AS "registerd users",(eth.count + 0.0) / (eth.owner_count + 0.0) AS "names per user",newusers.count AS "new .eth users",(newusers.count + 0.0) / (eth.owner_count + 0.0) AS "new user per user",noneth.count AS "non .eth name created",renew.count AS ".eth name renewed",0 - expired.count AS ".eth name expired",reverese.count AS "primary name set",(renew.count * 100 / (renew.count + released.count)) AS "renewal ratio (%)",0 - released.count AS ".eth name released"FROM(SELECT day, sum(name_count) as count, sum(owner_count) as owner_count FROM (SELECT DATE_TRUNC('day', call_block_time) AS day, count(*) AS name_count, COUNT(DISTINCT (wrappedOwner)) AS owner_count FROM ethereumnameservice_ethereum.NameWrapper_call_registerAndWrapETH2LDwhere call_block_time < date_trunc('day', CURRENT_TIMESTAMP)group by 1UNION ALLSELECTDATE_TRUNC('day', evt_block_time) AS day,COUNT(*) AS name_count,COUNT(DISTINCT (owner)) AS owner_countFROM-- ethereumnameservice.view_registrationsquery_2392498WHERE evt_block_time BETWEEN (CURRENT_TIMESTAMP - INTERVAL '90' day) AND DATE_TRUNC('day', CURRENT_TIMESTAMP) AND owner != 0xd4416b13d2b3a9abae7acd5d6c2bbdbe25686401 /* nameWrapper */GROUP BY 1) GROUP BY 1) AS ethLEFT JOIN (SELECTDATE_TRUNC('day', evt_block_time) AS day,COUNT(*) AS countFROM-- ethereumnameservice.view_renewalsquery_2404951WHEREevt_block_time > CURRENT_TIMESTAMP - INTERVAL '90' dayGROUP BY1) AS renew ON eth.day = renew.dayLEFT JOIN (SELECTDATE_TRUNC('day', max_evt_block_time) AS day,COUNT(*) AS countFROM-- ethereumnameservice.view_registries-- query_2406277 -- ethereumnameservice."view_registries"(selectnode,label,bytearray_to_uint256(label) as tokenid,min(evt_block_time) AS min_evt_block_time,