MCPcopy Create free account
hub / github.com/Effect-TS/effect / in_

Function in_

packages/effect/src/unstable/sql/Statement.ts:1505–1516  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1503function in_(values: ReadonlyArray<unknown>): ArrayHelper
1504function in_(column: string, values: ReadonlyArray<unknown>): Fragment
1505function in_(): Fragment | ArrayHelper {
1506 if (arguments.length === 1) {
1507 return arrayHelper(arguments[0])
1508 }
1509 const column = arguments[0]
1510 const values = arguments[1]
1511 return values.length === 0 ? neverFragment : fragment([
1512 identifier(column),
1513 literal(" IN "),
1514 arrayHelper(values)
1515 ])
1516}
1517
1518const neverFragment = fragment([literal("1=0")])

Callers

nothing calls this directly

Calls 4

arrayHelperFunction · 0.85
fragmentFunction · 0.85
identifierFunction · 0.70
literalFunction · 0.70

Tested by

no test coverage detected