Last active
May 27, 2017 18:28
-
-
Save przemyslawjanpietrzak/08788851287ce132182772d6912441ff to your computer and use it in GitHub Desktop.
databases-training
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select * from pracownicy; | |
select * from zespoly; | |
select NAZWISKO, PLACA_POD * 12 as "placa roczna" from pracownicy; | |
select ID_ZESP, NAZWA, ADRES from zespoly order by NAZWA; | |
select distinct ETAT from pracownicy; | |
select * from pracownicy where etat = 'ASYSTENT'; | |
select * from pracownicy where ID_ZESP in ('30', '40') order by PLACA_POD desc; | |
select * from pracownicy where PLACA_POD > 300 and PLACA_POD < 800; | |
select * from pracownicy where NAZWISKO like '%SKI'; | |
select * from pracownicy where PLACA_POD > 1000 and not ID_SZEFA is NULL; | |
select * from pracownicy where ID_ZESP = '20' and (NAZWISKO like 'M%' or NAZWISKO like '%SKI'); | |
select NAZWISKO, ETAT, PLACA_POD / 20 / 8 as "STAWKA" | |
from pracownicy | |
where not ETAT in ('ADIUNKT','ASYSTENT', 'STAZYSTA') and | |
(PLACA_POD <= 400 or PLACA_POD > 800) | |
order by STAWKA; | |
select * from pracownicy | |
where PLACA_POD + nvl(PLACA_DOD, 0) > 1000 | |
order by ETAT, NAZWISKO; | |
select NAZWISKO || ' PRACUJE OD ' || ZATRUDNIONY || ' I ZARABIA ' || PLACA_POD | |
from pracownicy | |
where ETAT = 'PROFESOR' | |
order by PLACA_POD desc; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment