"#" in string not comparable

I can’t seem to do any string operations testing for str=“#”. I don’t think this is a special character in a string but even putting “%#” before it does not work. I tried other things too with string operations. Can you check this please. Thanks.

I guess the problem must be somewhere else. Make sure you do not use any kind of unicode character and that the data that enters the comparison is ok.

I tested it with:

if "#" == "#" then
    print("it works")
end

if string.char(35) == "#" then
    print("it works too")
end