<< | Index | >>
pid1 = fork {
# sub process 1
3.times do
p "W"
200000000.times {}
end
}
pid2 = fork do
# sub process 2
3.times do
p "Q"
100000000.times {}
end
end
th1 = Process.detach(pid1)
th2 = Process.detach(pid2)
p th1.value
p th2.value
More simple one
10.times { |i|
pid = fork {
exec "sleep #{i}; echo #{i}"
}
}
p Process.waitall
system2
def system2 str
Process.wait2 fork {exec str}
end
system2 "sleep 1;echo 'A'"
system2 "sleep 2;echo 'B'"
system2 "sleep 3;echo 'C'"
p "END"
Note
Note
Updated
registration_data :comarketing_with, :complementary_type, :expiration_date,
:expired?, :export_flag, :fachinfo_active?, :generic_type,
:inactive_date, :pdf_fachinfos, :registration_date, :revision_date,
:patent, :patent_protected?, :vaccine, :parallel_import, :minifi,
:source, :index_therapeuticus, :ith_swissmedic, :has_fachinfo?, :production_science, :renewal_flag,
:renewal_flag_swissmedic
attr_accessor :registration_date, :export_flag, :company,
:revision_date, :indication, :expiration_date, :inactive_date,
:manual_inactive_date, :deactivate_fachinfo, :activate_fachinfo,
:market_date, :fachinfo, :source, :ikscat, :renewal_flag, #:pdf_fachinfos,
:renewal_flag_swissmedic,@
#renewal_flag = pack.renewal_flag
renewal_flag = pack.renewal_flag_swissmedic
if renewal_flag
@counts['renewal_flag'] += 1
end
boolean(renewal_flag)
Restart
Run
masa@masa ~/ywesee/oddb.org $ bin/admin ch.oddb> Updater.new(self).update_swissmedic -> Hash ch.oddb> exit -> Goodbye masa@masa ~/ywesee/oddb.org $ bin/admin ch.oddb> Updater.new(self).export_oddb_csv -> mhatakeyama@ywesee.com ch.oddb>
Note
Result
ODDB::SwissmedicPlugin - Report 06.04.2011 Created Packages: 384 Updated Packages: 18133 Deleted Packages: 89 (0 Replaced) Deleted Sequences: 209 Deactivated Registrations: 471 Updated new Export-Registrations: 0 Updated existing Export-Registrations: 433 Updated new Export-Sequences: 0 Updated existing Export-Sequences: 614 Total Sequences without ATC-Class: 12
anthroposophy 292
bsv_dossiers 3309
complementary 281
deductible_g 8623
deductible_o 49
duplicates 0
expiration_date 21858
export_registrations 668
galenic_forms 326
generics 4665
has_generic 0
homeopathy 806
inactive_date 4926
limitation_both 142
limitation_points 142
limitation_texts 1323
limitations 1323
lppv 600
missing_size 28
originals 2134
out_of_trade 3723
phytotherapy 1341
price_exfactory 9848
price_public 12374
registration_date 23491
renewal_flag 0
routes_of_administration 0
sl_entries 8672
masa@masa ~/ywesee/oddb.org $ bin/admin ch.oddb> ODDB::Package.find_by_pharmacode(1059082) -> #<ODDB::Package:0x7fd1844f48b0> ch.oddb> ODDB::Package.find_by_pharmacode(1059082).name -> Sirdalud 2 mg, Tabletten ch.oddb> ODDB::Package.find_by_pharmacode(1059082).renewal_flag -> true ch.oddb> ODDB::Package.find_by_pharmacode(1059082).renewal_flag_swissmedic ->
Note
Next
Commit