Check if two bytes are equal

How do you check the equality of two bytes on UDF?

This is standard Lua for comparing bytes, have you tried this?

local function compareByte(a, b)
    if string.byte(a) == string.byte(b) then
        return true
    else
        return false
    end
end
1 Like