Yes - that is how it works. The reason (I would speculate) is because many RDBMS systems use fixed length character data types (Access excluded) which result in trailing characters being "filled" with spaces. As such - you would want these to match with values in other variable length fields.
Do these spaces really have meaning and differentiate one value from another? So "A" has a different meaning to your application to "A "? You may wish to reconsider your coding. Alternatively you will have to do something to differentiate the two values.