MCPcopy Create free account
hub / github.com/Kilo-Org/cloud / sqlStringOrNull

Function sqlStringOrNull

packages/wl-sdk/src/commons/escape.ts:72–77  ·  view source on GitHub ↗
(s: string | null | undefined)

Source from the content-addressed store, hash-verified

70 * quoted, escaped value.
71 */
72export function sqlStringOrNull(s: string | null | undefined): string {
73 if (s === null || s === undefined || s === '') {
74 return 'NULL';
75 }
76 return sqlStringLiteral(s);
77}
78
79/**
80 * Renders a JavaScript value as a SQL literal. Supports the value shapes the

Callers 6

escape.test.tsFile · 0.90
insertWantedDMLFunction · 0.90
submitCompletionDMLFunction · 0.90
acceptCompletionDMLFunction · 0.90
acceptUpstreamDMLFunction · 0.90
closeUpstreamDMLFunction · 0.90

Calls 1

sqlStringLiteralFunction · 0.85

Tested by

no test coverage detected