Académique Documents
Professionnel Documents
Culture Documents
alter table A
add constraint pk_Z primary key (coluna1); Adiciona uma restrição a coluna1 na tabela A
alter table A
add coluna5 float; Adiciona uma coluna na tabela A
alter table A
add constraint rest_coluna2 check(coluna2 between 0 and 10); Adiciona uma restrição a coluna2 na tabela A
Entre 0 e 10 (Maior ou menor = ERRO)
alter table A
drop column coluna3; Apaga a coluna3 na tabela A
Aula 3
select * from A Seleção genérica na tabela A
select * from A where coluna1 = ’TESTE’ Seleção na coluna1 na tabela A por ‘TESTE’
select * from A
where coluna1 = ’TESTE’ or coluna1 = ’TESTE2’ Seleção na coluna1 por ‘TESTE’ ou ‘TESTE2’
select * from A
where coluna1 = ’TESTE’ and coluna1 = ’TESTE2’ Seleção na coluna1 por ‘TESTE’ e ‘TESTE2’
select * from A
where coluna1 = ’TESTE’ in (5,18) Seleção na coluna1 por ‘TESTE’ entre linhas 5 e 18
Aula 5
Aula 6
Aula 7