SHARE
TWEET

Untitled

a guest Dec 3rd, 2019 71 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. create table oseba(
  2.  
  3. id number(2),
  4.  
  5. ime varchar(30),
  6.  
  7. priimek varchar(30),
  8.  
  9. starost number(3)
  10.  
  11. );
  12.  
  13.  
  14.  
  15. insert into oseba(id,ime,priimek,starost)
  16.  
  17. values(1,'Marko','Arni�',18);
  18.  
  19.  
  20.  
  21. insert into oseba(id,ime,priimek,starost)
  22.  
  23. values(2,'Barbara','Bolha',19);
  24.  
  25.  
  26.  
  27. insert into oseba(id,ime,priimek,starost)
  28.  
  29. values(3,'Ale�','De�man',20);
  30.  
  31.  
  32.  
  33. insert into oseba(id,ime,priimek,starost)
  34.  
  35. values(4,'Teja','Kralj',22);
  36.  
  37.  
  38.  
  39. insert into oseba(id,ime,priimek,starost)
  40.  
  41. values(5,'Leon','Luznar',17);
  42.  
  43.  
  44.  
  45. select ime
  46.  
  47. from oseba;
  48.  
  49.  
  50.  
  51. select ime, priimek, starost
  52.  
  53. from oseba
  54.  
  55. where ime like 'M%';
  56.  
  57.  
  58.  
  59. select ime, priimek, starost
  60.  
  61. from oseba
  62.  
  63. where ime like 'M%o';
  64.  
  65.  
  66.  
  67. select ime, priimek, starost
  68.  
  69. from oseba
  70.  
  71. where ime like 'M%' or ime like 'B%';
  72.  
  73.  
  74.  
  75. select ime, priimek, starost
  76.  
  77. from oseba
  78.  
  79. where ime like 'M%' and priimek like 'A%';
  80.  
  81.  
  82.  
  83. select ime, priimek, starost
  84.  
  85. from oseba
  86.  
  87. where ime like '%l%';
  88.  
  89.  
  90.  
  91. select ime, priimek, starost
  92.  
  93. from oseba
  94.  
  95. where ime like '%arb%';
  96.  
  97.  
  98.  
  99. select ime, priimek, starost
  100.  
  101. from oseba
  102.  
  103. where ime like '_a%';
  104.  
  105.  
  106.  
  107. select ime, priimek
  108.  
  109. from oseba
  110.  
  111. where ime like '%o_';
  112.  
  113.  
  114.  
  115. select ime, priimek
  116.  
  117. from oseba
  118.  
  119. where ime like '_a%' and ime like '%k_';
  120.  
  121.  
  122.  
  123. select starost, ime, priimek
  124.  
  125. from oseba
  126.  
  127. where starost>18;
  128.  
  129.  
  130.  
  131. select starost, ime, priimek
  132.  
  133. from oseba
  134.  
  135. where starost<18;
  136.  
  137.  
  138.  
  139. select starost, ime, priimek
  140.  
  141. from oseba
  142.  
  143. where starost>18 and starost<25;
  144.  
  145.  
  146.  
  147. select starost, ime, priimek
  148.  
  149. from oseba
  150.  
  151. where starost between 18 and 25;
  152.  
  153.  
  154.  
  155. select starost, ime, priimek
  156.  
  157. from oseba
  158.  
  159. where starost between 18 and 25 and ime like'A%';
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top