the + operator resolves to the concatenation operator if used against an expression with a string type, or if using untyped elements concat() will get you there:
from sqlalchemy.sql import column
column('foo', String) + "bar"
column('foo').concat("bar")
your expression above appears to be evaluating a numeric against a string (so...this is MySQL ? :) ) you might consider calling cast(expr, String) on the numeric value before evaluating in a string context.
((score / 10) * 10).concat("-").concat((score / 10)*10) + 9).label('scorerange')
from sqlalchemy import cast, String
cast((score / 10) * 10, String).concat("-").concat(cast((score / 10)*10) + 9, String)).label('scorerange')
>
> --
> You received this message because you are subscribed to the Google Groups "sqlalchemy" group.
> To post to this group, send email to sqlal...@googlegroups.com.
> To unsubscribe from this group, send email to sqlalchemy+...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en.
>