Changeset 26258


Ignore:
Timestamp:
06/01/10 17:29:59 (7 years ago)
Author:
piotras
Message:

Fix SQL generated by query_builder_count. Make query aware of sid column.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/ragnaroek/midgard/core/midgard/src/query_builder.c

    r19676 r26258  
    465465               
    466466                g_string_append_printf(select, "COUNT(%s.guid) ", table);
     467                if (midgard_object_class_is_multilang (klass) && !builder->priv->unset_lang) {
     468                        g_string_append_printf(select, ", IFNULL(%s_i.sid, 0) AS sid ", table);
     469                }
    467470                return g_string_free(select, FALSE);
    468471        }
Note: See TracChangeset for help on using the changeset viewer.