[5e4f0d7] | 1 | delete from bolnica;
|
---|
| 2 | delete from bolnica_telefonski_broevi;
|
---|
| 3 | delete from covek;
|
---|
| 4 | delete from doktor;
|
---|
| 5 | delete from lekovi;
|
---|
| 6 | delete from oddel;
|
---|
| 7 | delete from pacient;
|
---|
| 8 | delete from pregled;
|
---|
| 9 | delete from recepta;
|
---|
| 10 | delete from rezervacija;
|
---|
| 11 | delete from specijalnost;
|
---|
| 12 | delete from telefonski_broevi;
|
---|
| 13 | delete from termin;
|
---|
| 14 | delete from transakcija;
|
---|
| 15 | delete from upat;
|
---|
| 16 |
|
---|
| 17 |
|
---|
| 18 |
|
---|
| 19 | insert into covek (covek_id, email, pass, ime, prezime, embg) values (1, 'petar.petrov@gmail.com', 'password1', 'Petar', 'Petrov', '1010995495005');
|
---|
| 20 | insert into covek (covek_id, email, pass, ime, prezime, embg) values (2, 'marija.aleksovska@gmail.com', 'password2', 'Marija', 'Aleksovska', '0101991490001');
|
---|
| 21 | insert into covek (covek_id, email, pass, ime, prezime, embg) values (4, 'stojan.gavrilov@gmail.com', 'password3', 'Stojan', 'Gavrilov', '0301000490111');
|
---|
| 22 | insert into covek (covek_id, email, pass, ime, prezime, embg) values (5, 'nikola.nikolovski@gmail.com', 'password4', 'Nikola', 'Nikolovski', '1512999450015');
|
---|
| 23 | insert into covek (covek_id, email, pass, ime, prezime, embg) values (6, 'elena.stojanovska@gmail.com', 'password5', 'Elena', 'Stojanovska', '1906987495017');
|
---|
| 24 | insert into covek (covek_id, email, pass, ime, prezime, embg) values (7, 'ivan.tasev@gmail.com', 'password6', 'Ivan', 'Tasev', '0301000491300');
|
---|
| 25 | insert into covek (covek_id, email, pass, ime, prezime, embg) values (8, 'gligor.petkov@gmail.com', 'password7', 'Gligor', 'Petkov', '0402987891891');
|
---|
| 26 | insert into covek (covek_id, email, pass, ime, prezime, embg) values (9, 'igor.milchev@gmail.com', 'password8', 'Igor', 'Milchev', '2009987123321');
|
---|
| 27 | insert into covek (covek_id, email, pass, ime, prezime, embg) values (10, 'janko.petkov@gmail.com', 'password9', 'Janko', 'Petkov', '3112002121212');
|
---|
| 28 | insert into covek (covek_id, email, pass, ime, prezime, embg) values (11, 'petar.stoev@gmail.com', 'password10', 'Petar', 'Stoev', '2104003490008');
|
---|
| 29 |
|
---|
| 30 |
|
---|
| 31 |
|
---|
| 32 | insert into telefonski_broevi (covek_broj_id, telefonski_broj) values (1, '070-552-111');
|
---|
| 33 | insert into telefonski_broevi (covek_broj_id, telefonski_broj) values (2, '070-552-222');
|
---|
| 34 | insert into telefonski_broevi (covek_broj_id, telefonski_broj) values (2, '070-552-333');
|
---|
| 35 | insert into telefonski_broevi (covek_broj_id, telefonski_broj) values (4, '070-552-444');
|
---|
| 36 | insert into telefonski_broevi (covek_broj_id, telefonski_broj) values (5, '070-552-555');
|
---|
| 37 | insert into telefonski_broevi (covek_broj_id, telefonski_broj) values (6, '070-552-666');
|
---|
| 38 | insert into telefonski_broevi (covek_broj_id, telefonski_broj) values (7, '070-552-777');
|
---|
| 39 | insert into telefonski_broevi (covek_broj_id, telefonski_broj) values (8, '070-552-888');
|
---|
| 40 | insert into telefonski_broevi (covek_broj_id, telefonski_broj) values (9, '070-552-999');
|
---|
| 41 | insert into telefonski_broevi (covek_broj_id, telefonski_broj) values (10, '070-552-121');
|
---|
| 42 | insert into telefonski_broevi (covek_broj_id, telefonski_broj) values (11, '070-552-122');
|
---|
| 43 | insert into telefonski_broevi (covek_broj_id, telefonski_broj) values (2, '070-552-123');
|
---|
| 44 |
|
---|
| 45 |
|
---|
| 46 |
|
---|
| 47 | insert into specijalnost (spec_id, naziv) values (1, 'Otorinolaringologija');
|
---|
| 48 | insert into specijalnost (spec_id, naziv) values (2, 'Dermatovenerologija');
|
---|
| 49 | insert into specijalnost (spec_id, naziv) values (3, 'Oftalmologija');
|
---|
| 50 | insert into specijalnost (spec_id, naziv) values (4, 'Ortopedija');
|
---|
| 51 | insert into specijalnost (spec_id, naziv) values (5, 'Interna medicina');
|
---|
| 52 | insert into specijalnost (spec_id, naziv) values (6, 'Kardiologija');
|
---|
| 53 | insert into specijalnost (spec_id, naziv) values (7, 'Ginekologija');
|
---|
| 54 | insert into specijalnost (spec_id, naziv) values (8, 'Pedijatrija');
|
---|
| 55 | insert into specijalnost (spec_id, naziv) values (9, 'Gastroenterohepatologija');
|
---|
| 56 | insert into specijalnost (spec_id, naziv) values (10, 'Semeen lekar');
|
---|
| 57 |
|
---|
| 58 |
|
---|
| 59 |
|
---|
| 60 | insert into bolnica (bolnica_id, naziv, grad, broj, ulica, smetka_bolnica) values
|
---|
| 61 | (1, 'Градска Општа болница „8 Септември"', 'Skopje', 3, 'Bledski Dogovor', '123456789'),
|
---|
| 62 | (2, 'Ј.З.У Специјална болница по гинекологија и акушерство „Мајка Тереза“', 'Skopje', 17, 'Majka Tereza', '213456789'),
|
---|
| 63 | (3, 'Универзитетската Клиника за Радиотерапија и Онкологија', 'Skopje', 17, 'Majka Tereza', '312456789'),
|
---|
| 64 | (4, 'ЈЗУ Универзитетски кардиолошки клинички центар', 'Skopje', 17, 'Majka Tereza', '412356789'),
|
---|
| 65 | (5, 'Градска Општа болница', 'Skopje', 10, '11 Oktomvri', '512346789');
|
---|
| 66 |
|
---|
| 67 |
|
---|
| 68 |
|
---|
| 69 | insert into bolnica_telefonski_broevi (bolnica_id, telefonski_br_bolnica) values
|
---|
| 70 | (1, '02 3087 400'),
|
---|
| 71 | (1, '02 3072 125'),
|
---|
| 72 | (2, '02 4323 132'),
|
---|
| 73 | (2, '02 3087 133'),
|
---|
| 74 | (3, '02 3087 405'),
|
---|
| 75 | (3, '02 3087 311'),
|
---|
| 76 | (4, '02 3087 500'),
|
---|
| 77 | (5, '02 3087 522');
|
---|
| 78 |
|
---|
| 79 |
|
---|
| 80 |
|
---|
| 81 | insert into oddel (bolnica_id, oddel_id, naziv, spec_id) values (1, 100, 'Pedijatrija', 8);
|
---|
| 82 | insert into oddel (bolnica_id, oddel_id, naziv, spec_id) values (2, 101, 'Ginekologija', 7);
|
---|
| 83 | insert into oddel (bolnica_id, oddel_id, naziv, spec_id) values (3, 102, 'Interna medicina', 5);
|
---|
| 84 | insert into oddel (bolnica_id, oddel_id, naziv, spec_id) values (4, 103, 'Kardiologija', 6);
|
---|
| 85 | insert into oddel (bolnica_id, oddel_id, naziv, spec_id) values (5, 104, 'Ortopedija', 4);
|
---|
| 86 | insert into oddel (bolnica_id, oddel_id, naziv, spec_id) values (5, 105, 'Otorinolaringologija', 1);
|
---|
| 87 | insert into oddel (bolnica_id, oddel_id, naziv, spec_id) values (1, 106, 'Dermatovenerologija', 2);
|
---|
| 88 | insert into oddel (bolnica_id, oddel_id, naziv, spec_id) values (5, 107, 'Oftalmologija', 3);
|
---|
| 89 | insert into oddel (bolnica_id, oddel_id, naziv, spec_id) values (5, 108, 'Gastroenterohepatologija', 9);
|
---|
| 90 | insert into oddel (bolnica_id, oddel_id, naziv, spec_id) values (1, 109, 'Opsta medicina', 10);
|
---|
| 91 |
|
---|
| 92 |
|
---|
| 93 |
|
---|
| 94 | insert into doktor (doktor_id, br_licenca, opis, spec_id, oddel_id, bolnica_id) values (2, 201, 'Specijalist', 1, 105, 5);
|
---|
| 95 | insert into doktor (doktor_id, br_licenca, opis, spec_id, oddel_id, bolnica_id) values (4, 202, 'Maticen', 10, 109, 1);
|
---|
| 96 | insert into doktor (doktor_id, br_licenca, opis, spec_id, oddel_id, bolnica_id) values (5, 203, 'Specijalist', 2, 106, 1);
|
---|
| 97 | insert into doktor (doktor_id, br_licenca, opis, spec_id, oddel_id, bolnica_id) values (6, 204, 'Specijalist', 6, 103, 4);
|
---|
| 98 | insert into doktor (doktor_id, br_licenca, opis, spec_id, oddel_id, bolnica_id) values (7, 205, 'Specijalist', 4, 104, 5);
|
---|
| 99 |
|
---|
| 100 |
|
---|
| 101 |
|
---|
| 102 | insert into Termin (termin_id, doktor_id, vreme) values (301, 2, now() + interval '3 days');
|
---|
| 103 | insert into Termin (termin_id, doktor_id, vreme) values (302, 2, now() + interval '4 days');
|
---|
| 104 | insert into Termin (termin_id, doktor_id, vreme) values (303, 2, now() + interval '3 days');
|
---|
| 105 | insert into Termin (termin_id, doktor_id, vreme) values (304, 6, now() + interval '5 days');
|
---|
| 106 | insert into Termin (termin_id, doktor_id, vreme) values (305, 6, now() + interval '5 days');
|
---|
| 107 | insert into Termin (termin_id, doktor_id, vreme) values (306, 5, now() + interval '6 days');
|
---|
| 108 | insert into Termin (termin_id, doktor_id, vreme) values (307, 5, now() + interval '10 days');
|
---|
| 109 | insert into Termin (termin_id, doktor_id, vreme) values (308, 7, now() + interval '2 days');
|
---|
| 110 | insert into Termin (termin_id, doktor_id, vreme) values (309, 7, now() + interval '8 days');
|
---|
| 111 | insert into Termin (termin_id, doktor_id, vreme) values (310, 7, ('2021-12-28 08:00')::timestamp);
|
---|
| 112 | insert into Termin (termin_id, doktor_id, vreme) values (311, 5, ('2021-12-25 12:00')::timestamp);
|
---|
| 113 |
|
---|
| 114 |
|
---|
| 115 |
|
---|
| 116 | insert into pacient (covek_pacient_id, pacient_id) values (1, 1001), (8, 1002), (9, 1003), (10, 1004), (11, 1005);
|
---|
| 117 |
|
---|
| 118 |
|
---|
| 119 |
|
---|
| 120 | insert into pregled (pregled_id, vreme, doktor_id, covek_pacient_id) values (1, now(), 2, 1), (2, now(), 4, 8), (3, now(), 5, 9), (4, now(), 6, 10), (5, now(), 7, 1);
|
---|
| 121 |
|
---|
| 122 |
|
---|
| 123 |
|
---|
| 124 | insert into upat (upat_id, dijagnoza, covek_pacient_id, pregled_id, bolnica_id, oddel_id) values (1, 'Bolki vo gradniot kos', 10, 4, 4, 103);
|
---|
| 125 | insert into upat (upat_id, dijagnoza, covek_pacient_id, pregled_id, bolnica_id, oddel_id) values (2, 'Crvenilo na kozata', 9, 3, 1, 106);
|
---|
| 126 | insert into upat (upat_id, dijagnoza, covek_pacient_id, pregled_id, bolnica_id, oddel_id) values (3, 'Bolki vo kolenoto', 1, 5, 5, 104);
|
---|
| 127 |
|
---|
| 128 |
|
---|
| 129 |
|
---|
| 130 | insert into rezervacija (rezervacija_id, upat_id, termin_id, doktor_id) values (500, 1, 304, 6), (501, 2, 306, 5), (502, 3, 309, 7);
|
---|
| 131 |
|
---|
| 132 |
|
---|
| 133 |
|
---|
| 134 | insert into transakcija (tran_id, suma, smetka_bolnica, rezervacija_id) values
|
---|
| 135 | (600, 50, '512346789', 502), (601, 20, '123456789', 501), (602, 20, '412356789', 500);
|
---|
| 136 |
|
---|
| 137 |
|
---|
| 138 |
|
---|
| 139 | insert into lekovi (lek_id, ime_lek, genericko_ime) values (800, 'Zantac', 'Ranitidine');
|
---|
| 140 | insert into lekovi (lek_id, ime_lek, genericko_ime) values (801, 'Glucophage', 'Metformin');
|
---|
| 141 | insert into lekovi (lek_id, ime_lek, genericko_ime) values (802, 'Prandin', 'Repaglinide');
|
---|
| 142 | insert into lekovi (lek_id, ime_lek, genericko_ime) values (803, 'Ticlid', 'Ticlopidine');
|
---|
| 143 | insert into lekovi (lek_id, ime_lek, genericko_ime) values (804, 'Nitroglycerin', 'Glyceryl trinitrate');
|
---|
| 144 | insert into lekovi (lek_id, ime_lek, genericko_ime) values (805, 'Cardura', 'Doxazosin');
|
---|
| 145 | insert into lekovi (lek_id, ime_lek, genericko_ime) values (806, 'Amoksiklav', 'Amoxicillin');
|
---|
| 146 |
|
---|
| 147 |
|
---|
| 148 |
|
---|
| 149 | insert into recepta (recepta_id, datum_izdavanje, datum_vaznost, datum_kupuvanje, pregled_id, lek_id, doktor_id, covek_pacient_id) values
|
---|
| 150 | (900, now(), now()+interval '10 days', now()+interval '1 days', 1, 800, 2, 1),
|
---|
| 151 | (901, now(), now()+interval '10 days', now()+interval '8 days', 2, 801, 4, 8);
|
---|
| 152 |
|
---|
| 153 |
|
---|
| 154 |
|
---|
| 155 | insert into recepta (recepta_id, datum_izdavanje, datum_vaznost, pregled_id, lek_id, doktor_id, covek_pacient_id) values
|
---|
| 156 | (902, now(), now()+interval '10 days', 3, 806, 5, 9);
|
---|
| 157 |
|
---|
| 158 |
|
---|