Skip to content

Write Primitives update_with_case_expression

Write Primitives benchmark · all Write Primitives queries

Representative SQL

Rendered in the benchmark’s native SQL with default parameters (no dialect translation available).

UPDATE update_ops_orders SET o_orderpriority = CASE
WHEN o_totalprice < 100000
THEN '5-LOW'
WHEN o_totalprice < 200000
THEN '4-NOT SPECIFIED'
WHEN o_totalprice < 300000
THEN '3-MEDIUM'
WHEN o_totalprice < 400000
THEN '2-HIGH'
ELSE '1-URGENT'
END, o_comment = 'case_update'
WHERE
o_orderkey <= (
SELECT
MIN(o_orderkey) + 100
FROM update_ops_orders
)

Representative DataFrame

No DataFrame implementation is registered for this query.

Get the exact query for your run

The blocks above are representative. To get the precise statement a specific platform runs at a specific scale, substitute your own values:

from benchbox import WritePrimitives
bench = WritePrimitives(scale_factor=0.01) # your scale factor
print(bench.get_queries()['update_with_case_expression'])

Source

Query text: benchbox/core/write_primitives/operations.py