Клиент серверные технологии (Курсовая работа - Информационная служба учета времени работы сотрудника), страница 2
Описание файла
Файл "Клиент серверные технологии" внутри архива находится в папке "Курсовая работа - Информационная служба учета времени работы сотрудника". Документ из архива "Курсовая работа - Информационная служба учета времени работы сотрудника", который расположен в категории "". Всё это находится в предмете "базы данных" из 6 семестр, которые можно найти в файловом архиве РТУ МИРЭА. Не смотря на прямую связь этого архива с РТУ МИРЭА, его также можно найти и в других разделах. Архив можно найти в разделе "курсовые/домашние работы", в предмете "базы данных (бд)" в общих файлах.
Онлайн просмотр документа "Клиент серверные технологии"
Текст 2 страницы из документа "Клиент серверные технологии"
select maker, speed
from product p inner join laptop l on p.model=l.model and hd >=10
select maker, speed
from product p cross join laptop l
where p.model=l.model and hd >=10
select maker, speed
from product, laptop
where product.model=laptop.model and laptop.hd >=10
<<< ---------------------------- >>>
Дисциплина «Базы данных» (см. схему на бумаге)
Укажите производителя и скорость ПК-блокнотов с жестким диском объемом не менее 10 Гбайт.
(укажите 3 правильных ответа)
Ответы:
1 - select maker, speed
from product p left join laptop l on p.model=l.model and hd >=10
where speed is not null
2 - select maker, speed
from product p right join laptop l on p.model=l.model and hd >=10
where speed is not null
3 - select maker, speed
from product p full join laptop l on p.model=l.model and hd >=10
where maker is not null and speed is not null
4 - select maker, speed
from product p inner join laptop l on product.model=laptop.model
where hd >=10
5 - select maker, speed
from product p inner join laptop l on hd >=10
where p.model=l.model
6 - select maker, speed
from product, (select maker, speed from laptop where hd >=10) as lap10
where product.model=laptop.model
ПРАВИЛЬНЫЕ ОТВЕТЫ:
select maker, speed
from product p left join laptop l on p.model=l.model and hd >=10
where speed is not null
select maker, speed
from product p full join laptop l on p.model=l.model and hd >=10
where maker is not null and speed is not null
select maker, speed
from product p inner join laptop l on hd >=10
where p.model=l.model
<<< ---------------------------- >>>
Дисциплина «Базы данных» (см. схему на бумаге)
Найдите список производителей (перечень уникальных наименований), продающего ПК, но не ПК-блокноты.
(укажите 3 правильных ответа)
Ответы:
1 - select distinct p1.maker
from product p1 left join product p2 on p1.maker=p2.maker and p2.type = 'laptop'
where p1.type='PC' and p2.maker is null
2 - select distinct maker
from product p
where type='PC' and not exists (select maker from product
where type='laptop' and p.maker=product.maker)
3 - select distinct p1.maker
from product p1 left join product p2 on p1.maker=p2.maker and p2.type = 'laptop'
where p1.type='pc' and p2.maker is null
4 - select distinct p1.maker
from product p1 inner join product p2 on p1.maker=p2.maker and p2.type = 'laptop'
where p1.type='PC' and p2.maker is null
5 - select distinct p1.maker
from product p1 left join product p2 on p1.maker=p2.maker
where p1.type='PC' and p2.maker is null and p2.type = 'laptop'
ПРАВИЛЬНЫЕ ОТВЕТЫ:
select distinct p1.maker
from product p1 left join product p2 on p1.maker=p2.maker and p2.type = 'laptop'
where p1.type='PC' and p2.maker is null
select distinct maker
from product p
where type='PC' and not exists (select maker from product
where type='laptop' and p.maker=product.maker)
select distinct p1.maker
from product p1 left join product p2 on p1.maker=p2.maker and p2.type = 'laptop'
where p1.type='pc' and p2.maker is null
<<< ---------------------------- >>>
Дисциплина «Базы данных» (см. схему на бумаге)
Найдите производителей (перечень уникальных значений) ПК с процессором не менее 450 Мгц. Вывести: Maker
(укажите 4 правильных ответа)
Ответы:
1 - select distinct maker
from product left join pc on pc.model=product.model and speed>=450
where pc.code is not null
2 - select distinct maker from product, pc
where pc.model=product.model and not speed<450
3 - select distinct maker
from product right join pc on pc.model=product.model and speed>=450
where maker is not null
4 - select distinct maker from product
where model in (select model from pc
where pc.model=product.model and speed>=450)
5 - select distinct maker
from product left join pc on pc.model=product.model and speed>=450
where product.model is null
6 - select distinct maker from product right join pc on pc.model=product.model and speed>=450
where product.model is null
ПРАВИЛЬНЫЕ ОТВЕТЫ:
select distinct maker
from product left join pc on pc.model=product.model and speed>=450
where pc.code is not null
select distinct maker from product, pc
where pc.model=product.model and not speed<450
select distinct maker
from product right join pc on pc.model=product.model and speed>=450
where maker is not null
select distinct maker from product
where model in (select model from pc
where pc.model=product.model and speed>=450)
<<< ---------------------------- >>>
Дисциплина «Базы данных» (см. схему на бумаге)
Найдите производителей (перечень уникальных значений) ПК с процессором не менее 450 Мгц. Вывести: Maker
(укажите 4 правильных ответа)
Ответы:
1 - select distinct maker
from product
where exists (select model from pc where pc.model=product.model and not speed<450)
2 - select distinct maker
from product inner join pc
on pc.model=product.model and speed>=450
3 - select distinct maker
from product
where model not in (select model from pc where speed>=450)
4 - select distinct maker
from product right join pc on pc.model=product.model
on product.model is not null and speed>=450
5 - select distinct maker
from product right join pc
on pc.model=product.model where product.model is not null and speed>=450
6 - select distinct maker
from product
where model in (select model from pc
group by model, speed having speed>=450)
ПРАВИЛЬНЫЕ ОТВЕТЫ:
select distinct maker
from product
where exists (select model from pc where pc.model=product.model and not speed<450)
select distinct maker
from product inner join pc
on pc.model=product.model and speed>=450
select distinct maker
from product right join pc
on pc.model=product.model where product.model is not null and speed>=450
select distinct maker
from product
where model in (select model from pc
group by model, speed having speed>=450)
<<< ---------------------------- >>>
Дисциплина «Базы данных» (см. схему на бумаге)
Найдите принтеры, имеющие самую высокую цену. Вывести: model, price
(укажите 3 правильных ответа)
Ответы:
1 - select model, price from printer
where price = (select max(price) from printer)
2 - select model, price from printer
group by model, price having price = (select max(price) from printer)
3 - select model,
(select max(price) maxi from printer where printer.model= pr1.model) 'Price'
from printer as pr1
4 - select model, price from printer
where price = (select max(price) maxi from printer)
group by model, price
5 - select model, price from printer
where price = max(select price from printer)
6 - select model, price
from printer cross join (select max(price) maxi from printer) as max_price
where max(price) = max_price.maxi
ПРАВИЛЬНЫЕ ОТВЕТЫ:
select model, price from printer
where price = (select max(price) from printer)
select model, price from printer
group by model, price having price = (select max(price) from printer)
select model, price from printer
where price = (select max(price) maxi from printer)
group by model, price
<<< ---------------------------- >>>
Дисциплина «Базы данных» (см. схему на бумаге)
Найдите принтеры, имеющие самую высокую цену. Вывести: model, price
(укажите 4 правильных ответа)
Ответы:
1 - select model, price from printer inner join
(select max(price) maxi from printer) as max_price on price = max_price.maxi
2 - select model, price from printer left join
(select max(price) maxi from printer) as max_price on price = max_price.maxi where maxi is not null
3 - select model, max(price) as 'Price' from printer
where price in (select max(price) maxi from printer) group by model
4 - select model, price from printer
group by model, price having price = (select max(price) maxi from printer)
5 - select model, price from printer
left join (select max(price) maxi from printer) as max_price on price = max_price.maxi
6 - select model, price from printer
where price = max(select price from printer)
ПРАВИЛЬНЫЕ ОТВЕТЫ:
select model, price from printer inner join
(select max(price) maxi from printer) as max_price on price = max_price.maxi
select model, price from printer left join
(select max(price) maxi from printer) as max_price on price = max_price.maxi where maxi is not null
select model, max(price) as 'Price' from printer
where price in (select max(price) maxi from printer) group by model
select model, price from printer
group by model, price having price = (select max(price) maxi from printer)
<<< ---------------------------- >>>
Дисциплина «Базы данных» (см. схему на бумаге)
Найдите принтеры, имеющие самую высокую цену. Вывести: model, price
(укажите 2 правильных ответа)
Ответы:
1 - select model, price from printer
left join (select max(price) maxi from printer) as max_price on price = max_price.maxi
where maxi is not null
2 - select model, (select max(price) maxi from printer where printer.model= pr1.model) 'Price'
from printer as pr1
3 - select model, price from printer
where price in (select max(price) maxi from printer)
4 - select model, max(select price from printer where printer.model= pr1.model) 'Price'
from printer as pr1
ПРАВИЛЬНЫЕ ОТВЕТЫ:
select model, price from printer
left join (select max(price) maxi from printer) as max_price on price = max_price.maxi
where maxi is not null
select model, price from printer
where price in (select max(price) maxi from printer)
<<< ---------------------------- >>>
Дисциплина «Базы данных» (см. схему на бумаге)
Найдите принтеры, имеющие самую высокую цену. Вывести: model, price