Index: openacs-4/packages/ecommerce/www/admin/cat/subcategory-add-0.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/www/admin/cat/subcategory-add-0.tcl,v diff -u -N -r1.1 -r1.2 --- openacs-4/packages/ecommerce/www/admin/cat/subcategory-add-0.tcl 20 Apr 2001 20:51:13 -0000 1.1 +++ openacs-4/packages/ecommerce/www/admin/cat/subcategory-add-0.tcl 17 Jul 2001 23:59:03 -0000 1.2 @@ -24,11 +24,15 @@ # (average of prev_sort_key and next_sort_key); # otherwise warn them that their form is not up-to-date +### gilbertw - added do the calculation outside of the db. PostgreSQL encloses +# the bind variables in ' ' +# where sort_key = (:prev_sort_key + :next_sort_key)/2 +set sort_key [expr ($prev_sort_key + $next_sort_key)/2] set n_conflicts [db_string get_n_conflicts "select count(*) from ec_subcategories where category_id=:category_id -and sort_key = (:prev_sort_key + :next_sort_key)/2"] +and sort_key = :sort_key"] if { $n_conflicts > 0 } { ad_return_complaint 1 "
  • The page you came from appears to be out-of-date;