-
Type: New Feature
-
Resolution: Duplicate
-
Priority: Minor - P4
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
The aggregation framework is great and has very powerful operators. You can apply string operations, calculate with numbers and dates etc. Unfortunately you must have the right type to begin with to make use of all these That's not always the case! For instance it is sufficient that you have a field containing "7x8" and there's nothing you can do to calculate (i.e. area in sqm) or compare anything (numerically). Especially, I'm missing an operator to at least convert a string to an integer: {$cast=>"number"} or something like that. I hope, this isn't too complicated to implement - that's why I'm proposing it here. Being able to use it for normal queries (i.e. without aggregaton) would be very cool as well.
- duplicates
-
SERVER-6206 need a policy for incompatible types in operators in aggregation expressions
- Closed
-
SERVER-6203 Aggregation operators should have well defined implicit type coercion behavior.
- Backlog