db: fix fn_db_add_config_value_for_versions_up_to
db: fix fn_db_add_config_value_for_versions_up_to

The FOREACH keyword used in the function is not compatible with PG 8.x
and was replaced with a FOR loop that is supported for both 8.x and 9.x

Change-Id: Ice6f9425fae64ebdd4bfcc68d848ec4fdd9acc8a
Signed-off-by: emesika <dc8a2a200abf66067593de2e51fee9376f06ea0f@redhat.com>

zerodengxinchao/ovirt-engine,yapengsong/ovirt-engine,eayun/ovirt-engine,zerodengxinchao/ovirt-engine,walteryang47/ovirt-engine,walteryang47/ovirt-engine,OpenUniversity/ovirt-engine,walteryang47/ovirt-engine,OpenUniversity/ovirt-engine,zerodengxinchao/ovirt-engine,yingyun001/ovirt-engine,yapengsong/ovirt-engine,eayun/ovirt-engine,yapengsong/ovirt-engine,yapengsong/ovirt-engine,zerodengxinchao/ovirt-engine,walteryang47/ovirt-engine,eayun/ovirt-engine,OpenUniversity/ovirt-engine,yingyun001/ovirt-engine,yingyun001/ovirt-engine,zerodengxinchao/ovirt-engine,OpenUniversity/ovirt-engine,yingyun001/ovirt-engine,eayun/ovirt-engine,yapengsong/ovirt-engine,OpenUniversity/ovirt-engine,walteryang47/ovirt-engine,yingyun001/ovirt-engine,eayun/ovirt-engine