Questões de Concurso Público MPE-SC 2014 para Analista em Tecnologia da Informação, Reaplicação
Foram encontradas 3 questões
drop table teste;
create table teste (
val NUMBER,
descricao varchar2(15)
);
insert all
into teste
into teste
SELECT level,
SUBSTR(dbms_random.string(‘U’,10),1,10)
from dual connect by level < 10;
commit;
select count(*) from teste;
drop table teste;
create table teste (
val NUMBER,
descricao varchar2(15)
);
insert all
into teste
into teste
SELECT level,
SUBSTR(dbms_random.string(‘U’,10),1,10)
from dual connect by level < 10;
commit;
SELECT val
FROM teste
WHERE val >= 0 and val < 6
ORDER BY val
OFFSET 4 ROWS FETCH NEXT 20 PERCENT
ROWS ONLY;
drop table teste;
create table teste (
val NUMBER,
descricao varchar2(15)
);
insert all
into teste
into teste
SELECT level,
SUBSTR(dbms_random.string(‘U’,10),1,10)
from dual connect by level < 10;
commit;
SELECT val
FROM teste
WHERE val < 10 and val > 5
ORDER BY val DESC
FETCH FIRST 5 ROWS WITH TIES;