MCPcopy
hub / github.com/umami-software/umami / getTimestampDiffSQL

Function getTimestampDiffSQL

src/lib/prisma.ts:97–99  ·  view source on GitHub ↗
(field1: string, field2: string)

Source from the content-addressed store, hash-verified

95}
96
97function getTimestampDiffSQL(field1: string, field2: string): string {
98 return `floor(extract(epoch from (${field2} - ${field1})))`;
99}
100
101function getSearchSQL(column: string, param: string = 'search'): string {
102 return `and ${column} ilike {{${param}}}`;

Callers 7

relationalQueryFunction · 0.85
relationalQueryFunction · 0.85
relationalQueryFunction · 0.85
relationalQueryFunction · 0.85
relationalQueryFunction · 0.85
relationalQueryFunction · 0.85
relationalQueryFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected