Mercurial > hgrepos > hgweb.cgi > s4
comparison s4-world.sh @ 880:fa5be649968f
Omit update of user_m when no records in user_s modified
author | HIROSE Yuuji <yuuji@gentei.org> |
---|---|
date | Mon, 14 Dec 2020 20:01:07 +0900 |
parents | ed9aae18fda9 |
children | a240c8988c65 |
comparison
equal
deleted
inserted
replaced
879:188ad98d443f | 880:fa5be649968f |
---|---|
87 err "Force update user_m for all users" | 87 err "Force update user_m for all users" |
88 else | 88 else |
89 case "$prevsync" in | 89 case "$prevsync" in |
90 [2-9][0-9][0-9][0-9]-[01][0-9]-[0-3][0-9]\ [012][0-9]:??:??) | 90 [2-9][0-9][0-9][0-9]-[01][0-9]-[0-3][0-9]\ [012][0-9]:??:??) |
91 SYNCCOND="WHERE name in (SELECT name FROM m.user_s WHERE key='wtime' AND val > '$prevsync')" | 91 SYNCCOND="WHERE name in (SELECT name FROM m.user_s WHERE key='wtime' AND val > '$prevsync')" |
92 err synccond limited to \ | 92 err "prevsync=$prevsync" |
93 `query "SELECT DISTINCT name FROM m.user_s $SYNCCOND;"` | 93 limited=`query "SELECT DISTINCT name FROM m.user_s $SYNCCOND;"` |
94 if [ -n "$limited" ]; then | |
95 err synccond limited to "$limited" | |
96 else | |
97 err synccond canceled for user_m | |
98 SYNCCOND="WHERE NULL" | |
99 fi | |
94 err "Touch $syncall (owner=`id -un`) to update all user_m." | 100 err "Touch $syncall (owner=`id -un`) to update all user_m." |
95 ;; | 101 ;; |
96 *) | 102 *) |
97 echo arere ;; | 103 echo arere ;; |
98 esac | 104 esac |