tsranges
https://www.percona.com/blog/using-the-multirange-data-type-in-postgresql-14/
globally unique ids https://supabase.com/blog/choosing-a-postgres-primary-key
//LOAD CSV script for GFTS data | |
create constraint on (a:Agency) assert a.id is unique; | |
create constraint on (r:Route) assert r.id is unique; | |
create constraint on (t:Trip) assert t.id is unique; | |
create index on :Trip(service_id); | |
create constraint on (s:Stop) assert s.id is unique; | |
create index on :Stoptime(stop_sequence); | |
create index on :Stop(name); | |
schema await |
--Table | |
CREATE TABLE IF NOT EXISTS person ( | |
id integer NOT NULL, | |
person_name character varying(40) NOT NULL, | |
updated_date date, | |
CONSTRAINT person_pkey PRIMARY KEY (id) | |
); | |
--Index | |
CREATE INDEX IF NOT EXISTS idx_person_name ON person (person_name); |
db.getCollection("versioned").aggregate( | |
[ | |
{ $sort: { __version: -1 }}, | |
{ $group: { _id: "$UUID", doc: { $first: "$$ROOT" }}}, | |
{ $replaceWith: "$doc" } | |
], | |
{ collation: { locale: 'en', numericOrdering: true }} | |
) |
export const FREE_ROOMS = groq` | |
*[_type == 'room' && count(*[_type == 'booking' && ^._id in room[]._ref && ((checkin >= $ci && checkin <= $co)||(checkin <= $ci && checkout >= $ci))]) == 0]{...} | |
`; |
{ | |
"meta": { | |
"theme": "professional" | |
}, | |
"basics": { | |
"name": "Ricardo Casares", | |
"label": "Full Stack Human", | |
"email": "[email protected]", | |
"phone": "", | |
"summary": "A web craftsman, passionate about the Internet and new technologies.", |
import * as Pattern from "url-pattern"; | |
import { Dispatch, Middleware } from "redux"; | |
export interface Options { | |
actions: string[]; | |
routes: { | |
[x: string]: (store: Dispatch, params: any) => any; | |
}; | |
} |
All of the below properties or methods, when requested/called in JavaScript, will trigger the browser to synchronously calculate the style and layout*. This is also called reflow or layout thrashing, and is common performance bottleneck.
elem.offsetLeft
, elem.offsetTop
, elem.offsetWidth
, elem.offsetHeight
, elem.offsetParent
elem.clientLeft
, elem.clientTop
, elem.clientWidth
, elem.clientHeight
elem.getClientRects()
, elem.getBoundingClientRect()
/** | |
* This script was succesfuly tested on JIRA 6.1 | |
*/ | |
// import JIRA Component Accessor | |
import com.atlassian.jira.component.ComponentAccessor | |
// Create a new instance | |
cA = new ComponentAccessor(); | |
// Get all application users | |
users = cA.getUserManager().getAllApplicationUsers(); |