-
Brian King authored
Fix ordering of forums when there are more than 10 forums ANSI SQL function CHAR_LENGTH (works on postgresql and mysql) is used to help sort the forums in the correct order. Without this, if you have 11 forums, the 'order by' using the varchar weight value results in them being ordered 0, 1, 10, 2, 3, .... Apparently there is no my- and postgresql compatible syntax to cast strings to integers, so this patch orders first by string length, then by string value of the column storing the weight of the forum. Change-Id: I715f52d097189b9d3988339984220185cc1d6498 Signed-off-by: Brian King <brian@liip.ch>
75f3ed93