← greater operator page · comparison/greater/sc_sc/alphabetical_string_order

Alphabetical string order 🟢 all ok

pandas ✅ · DuckDB ✅

Tests:

SC_1 > SC_2 with SC_1 = "hello" and SC_2 = "hi": two strings.

Manual:

Greater than, semantics for scalar operations: "``"hello" > "hi"`` gives false".

Expected:

SC_r = false, a Boolean, as the page gives it: hello sorts before hi.

script.vtl ⇩

SC_r := SC_1 > SC_2;

input/scalars.csv ⇩

SC_1SC_2
hellohi

input/scalars.json ⇩

{
  "scalars": [
    {"name": "SC_1", "type": "String"},
    {"name": "SC_2", "type": "String"}
  ]
}

expected/scalars.json ⇩

{
  "scalars": [
    {"name": "SC_r", "type": "Boolean", "value": false}
  ]
}