临时代码

  • A+
所属分类:项目

ALTER SEQUENCE dept_id_seq RESTART WITH 100;
ALTER SEQUENCE doc_id_seq RESTART WITH 100;
ALTER SEQUENCE pat_id_seq RESTART WITH 100;
ALTER SEQUENCE diagnose_item_id_seq RESTART WITH 100;
ALTER SEQUENCE diagnose_record_id_seq RESTART WITH 100;
ALTER SEQUENCE medical_item_id_seq RESTART WITH 100;
ALTER SEQUENCE medical_record_id_seq RESTART WITH 100;

SELECT
(SELECT count(*) FROM dept) dept
,(SELECT count(*) FROM doc) doc
,(SELECT count(*) FROM pat) pat
,(SELECT count(*) FROM diagnose_item) diagnose_item
,(SELECT count(*) FROM diagnose_record) diagnose_record
,(SELECT count(*) FROM medical_item) medical_item
,(SELECT count(*) FROM medical_record) check_record
;
-- 9 18 9 0 0 9 18

DELETE FROM medical_record WHERE id > 99;
DELETE FROM medical_item WHERE id > 99;
DELETE FROM diagnose_record WHERE id > 99;
DELETE FROM diagnose_item WHERE id > 99;
DELETE FROM pat WHERE id > 99;
DELETE FROM doc WHERE id > 99;
DELETE FROM dept WHERE id > 99;

 

 

443a7f79e1ca9711

[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm"

 

wget https://npm.taobao.org/mirrors/node/v8.1.1/node-v8.1.1-linux-x64.tar.gz
sudo tar --strip-components 1 -xzvf node-v* -C /usr/local

 

=== plpython3u ===
[Mac]
brew install python3
[Ubuntu]
apt-get install python3
[CentOS7]
wget https://www.python.org/ftp/python/3.6.1/Python-3.6.1.tgz
tar zxvf Python-3.6.1.tgz
cd Python-3.6.1
./configure --enable-shared --enable-optimizations
make && make install

pip3 install requests

=== plv8 ===
brew install v8 [可选]
wget http://updates.xtuple.com/updates/plv8/mac/xtuple_plv8.tgz
tar -zxvf xtuple_plv8.tgz
sudo sh -x install_plv8.sh
更多版本:https://github.com/plv8/plv8/issues/220

楚廉
  • 版权声明:本站原创文章,于2017年11月28日17:05:23,由 发表,共 1451 字。
  • 转载请注明:临时代码 | yeernet

发表评论

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen: