source: cpc/trunk/project/bin/updateDB3.sh @ 2686

Last change on this file since 2686 was 1675, checked in by goya, 11 years ago

oups commit malheureux corrigé

File size: 4.8 KB
Line 
1#!/bin/bash
2
3source bin/db.inc
4
5php symfony cc
6#php symfony doctrine:build --all-classes
7#cat bin/updateDB3.model.sql | mysql $MYSQLID $DBNAME
8php symfony doctrine:build --all --no-confirmation
9
10echo "ALTER TABLE parlementaire ADD photo LONGBLOB NULL AFTER profession" | mysql $MYSQLID $DBNAME
11
12zcat data/sql/dumps/nosdeputes_prod.100925.sql.gz | mysql --default-character-set=utf8 $MYSQLID $DBNAME
13
14echo "ALTER TABLE parlementaire DROP photo" | mysql $MYSQLID $DBNAME
15
16cat bin/updateDB3.1.sql | mysql $MYSQLID $DBNAME
17
18bash bin/load_deputes
19
20cd batch/hemicycle
21perl parse_hemicycle.pl html/http\:__www.assemblee-nationale.fr_13_cri_2007-2008_20080120.asp > out/out1
22perl parse_hemicycle.pl html/http\:__www.assemblee-nationale.fr_13_cri_2008-2009_20090021.asp > out/out2
23perl parse_hemicycle.pl html/http\:__www.assemblee-nationale.fr_13_cri_2007-2008_20080086.asp > out/out3
24perl parse_hemicycle.pl html/http\:__www.assemblee-nationale.fr_13_cri_2008-2009-extra2_20092014.asp > out/out4
25perl parse_hemicycle.pl html/http\:__www.assemblee-nationale.fr_13_cri_2009-2010_20100162.asp > out/out5
26perl parse_hemicycle.pl html/http\:__www.assemblee-nationale.fr_13_cri_2007-2008_20080193.asp > out/out6
27perl parse_hemicycle.pl html/http\:__www.assemblee-nationale.fr_13_cri_2008-2009_20090221.asp > out/out7
28perl parse_hemicycle.pl html/http\:__www.assemblee-nationale.fr_13_cri_2009-2010-extra_20101013.asp > out/out8
29perl parse_hemicycle.pl html/http\:__www.assemblee-nationale.fr_13_cri_2006-2007-extra2_20072008.asp > out/out9
30perl parse_hemicycle.pl html/http\:__www.assemblee-nationale.fr_13_cri_2008-2009_20090242.asp > out/out10
31cd -
32
33while ls batch/hemicycle/out | grep [a-z] > /dev/null ; do 
34        php symfony cc --env=test  --app=frontend > /dev/null
35        php symfony load:Hemicycle
36done;
37
38php symfony move:Seance 304 13 31
39php symfony move:Seance 278 1043 31
40php symfony move:Seance 84 1043 31
41php symfony move:Seance 2756 1043 7573
42php symfony move:Seance 2769 1043 7573
43php symfony move:Seance 59 785 254
44php symfony move:Seance 311 785 181
45php symfony move:Seance 59 784 254
46php symfony move:Seance 311 784 181
47php symfony move:Seance 311 7004 181
48php symfony move:Seance 521 5039 357
49php symfony move:Seance 3194 8634 2
50php symfony move:Seance 108 1356 1348
51php symfony move:Seance 281 3362 2765
52php symfony move:Seance 48 621 1380
53php symfony move:Seance 348 4185 2
54php symfony move:Seance 2903 7751 7573
55php symfony move:Seance 3639 10334 2
56php symfony move:Seance 3473 1213 2
57php symfony move:Seance 3264 8874 2
58
59cat bin/updateDB3.2.sql | mysql $MYSQLID $DBNAME
60
61php symfony fuse:Dossiers 5091 9804
62php symfony fuse:Dossiers 3511 952
63php symfony fuse:Dossiers 2867 952
64php symfony fuse:Dossiers 547 357
65php symfony fuse:Dossiers 6576 1993
66php symfony fuse:Dossiers 46 1993
67php symfony fuse:Dossiers 8897 8900
68php symfony fuse:Dossiers 7558 7573
69php symfony fuse:Dossiers 7591 7573
70php symfony fuse:Dossiers 927 1926
71php symfony fuse:Dossiers 733 4450
72php symfony fuse:Dossiers 4825 4450
73php symfony fuse:Dossiers 5911 4450
74php symfony fuse:Dossiers 1421 31
75php symfony fuse:Dossiers 1011 4321
76php symfony fuse:Dossiers 2783 195
77php symfony fuse:Dossiers 1443 2363
78php symfony fuse:Dossiers 6879 5549
79php symfony fuse:Dossiers 8837 1384
80php symfony fuse:Dossiers 7551 7521
81php symfony fuse:Dossiers 8740 8663
82php symfony fuse:Dossiers 9424 9427
83php symfony fuse:Dossiers 10869 10790
84php symfony fuse:Dossiers 9833 9718
85php symfony fuse:Dossiers 9747 9837
86php symfony fuse:Dossiers 7005 7038
87php symfony fuse:Dossiers 3201 4773
88php symfony fuse:Dossiers 5034 5470
89php symfony fuse:Dossiers 9842 9804
90php symfony fuse:Dossiers 3790 181
91php symfony fuse:Dossiers 5828 2675
92php symfony fuse:Dossiers 515 2811
93php symfony fuse:Dossiers 813 2814
94php symfony fuse:Dossiers 3759 5050
95php symfony fuse:Dossiers 3904 964
96php symfony fuse:Dossiers 10999 9328
97php symfony fuse:Dossiers 10772 9485
98php symfony fuse:Dossiers 10331 10354
99php symfony fuse:Dossiers 7983 8003
100php symfony fuse:Dossiers 8611 4974
101php symfony fuse:Dossiers 914 2370
102php symfony fuse:Dossiers 265 16
103php symfony fuse:Dossiers 2348 6376
104php symfony fuse:Dossiers 9485 10874
105php symfony fuse:Dossiers 3955 3953
106
107cat bin/updateDB3.3.sql | mysql $MYSQLID $DBNAME
108
109echo > /tmp/res_maxdate
110while grep -v "^0 sections trouvées" /tmp/res_maxdate > /dev/null ; do 
111        php symfony cc --env=test  --app=frontend > /dev/null
112        php symfony set:MaxDateDossiers > /tmp/res_maxdate
113done;
114rm -f /tmp/res_maxdate
115
116cd batch/documents
117  mkdir ppr
118  mkdir pjl
119  mkdir ppl
120  mkdir rap
121  mkdir ta
122  mkdir out
123  perl download_docs.pl
124  for dir in rap ppl pjl ppr ta; do
125    for file in `ls $dir`; do
126      perl parse_metas.pl $dir/$file > out/$file
127    done
128  done
129cd -
130
131
132while ls batch/documents/out | grep [a-z] > /dev/null ; do 
133        php symfony cc --env=test  --app=frontend > /dev/null
134        php symfony load:Documents
135done;
136
137php symfony top:Deputes
138bash bin/update_tops.sh
139
140#bash bin/update_hardcache_all
141
142
143
Note: See TracBrowser for help on using the repository browser.