Главная | Обратная связь | Поможем написать вашу работу!
МегаЛекции

Teach YourSelf 4 страница




('5163903414020', 'ЦРД-99', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Авиамоторика им В. В. Тарасова'), '41003941503166', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПСИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('19152087', 'ДП-110', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Гидроавтоматика'), '41003941503166', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('19151124', 'ДТ-211', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Аэроприбор-Восход'), '41003941503166', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПСИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 1, NOW(), null),

('8686475205', 'КВФ-222-6', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Аэроэлектромаш'), '41003941503166', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('6305455054', 'КВФ-222-6', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Высокие технологии'), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('4402043', 'СПТ-88-2. 2У', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'КБ " Электроприбор" '), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('051510083', 'ДЧВ-2500А', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Климов'), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('163008', 'П-109', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Прибор'), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПСИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('50257', 'ДАТ-4', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Приматекс'), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПСИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 1, NOW(), null),

('215367', 'ДС-11В', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'ОКБ " Кристалл" '), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПСИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('1618619', 'Т-142', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Техприбор'), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПСИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('4401767', 'СП-0. 6ЭТ1', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'НПП " Темп им. Ф. Короткова" '), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПСИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('10104605114', 'ТДК-М', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'МПО им. Румянцева'), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПСИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(),  null),

('0915644', '6139Т', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Мотор Сич'), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('2026360919', 'ДПИ-1500-5МЛ(5Л)', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'МНПК " Авионика" '), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПСИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 1, NOW(), null),

('37073', 'МСТ-6. 5', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'ММЗ " Знамя" '), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('604500175', 'МКВ-253А', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Красный Октябрь'), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПСИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('6305075448', 'СП-87ПА', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Утес'), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('36937', 'МСТВ-1', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'Электроавтомат'), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ТИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('2026360893', 'ДПИ-1500-5МПР(5ПР)', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'ЭОКБ " Сигнал им. Глухарева" '), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПСИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null),

('Г16060', '39. 10. 84. 000', (SELECT idOrganisation FROM organisations WHERE Name_of_company = 'АК " Рубин" '), '41003931503149', (SELECT idTechnical_state FROM technical_states WHERE State = 'Исправное состояние (good state)'), (SELECT idType_of_technical_service FROM technical_services WHERE Type_of_technical_service = 'Обслуживаемый объект (maintainable item)'), (SELECT idType_of_test FROM types_of_test WHERE Name_of_test = 'ПИ'), (SELECT idBelongings FROM belongings WHERE Belonging = 'ИЗ'), 0, NOW(), null);

 

 

INSERT INTO temp_company. types_of_failure_by_gost_15467 (Type_of_failure, Description_of_failure) VALUES

('Ресурсный отказ (Marginal failure)', 'Отказ, в результате которого объект достигает предельного состояния. '),

('Независимый отказ (Primary failure)', 'Отказ, не обусловленный другими отказами'),

('Зависимый отказ (Secondary failure)', 'Отказ, обусловленный другими отказами. '),

('Внезапный отказ (Sudden failure)', 'Отказ, характеризующийся скачкообразным изменением значений одного или нескольких параметров объекта. '),

('Постепенный отказ (Gradual failure)', 'Отказ, возникающий в результате постепенного изменения значений одного или нескольких параметров объекта'),

('Сбой (Interruption)', 'Самоустраняющийся отказ или однократный отказ, устраняемый незначительным вмешательством оператора'),

('Перемежающийся отказ (Intermittent failure)', 'Многократно возникающий самоустраняющийся отказ одного и того же характера'),

('Явный отказ (Explicit failure)', 'Отказ, обнаруживаемый визуально или штатными методами и средствами контроля и диагностирования при подготовке объекта к применению или в процессе его применения по назначению'),

('Скрытый отказ (Latent failure)', 'Отказ, не обнаруживаемый визуально или штатными методами и средствами контроля и диагностирования, но выявляемый при проведении технического обслуживания или специальными методами диагностики');

 

INSERT INTO temp_company. units_has_defects

(Units_Units_idCode_of_unit, Units_Units_idNumber_of_engine, Units_Units_№Unit, Units_Units_Type_of_units_Manufacturer_organisation_of_unit, Defects_idDefect) VALUES

(('НР-31Н1'), '41003931503149', '33906615002', 1, 2);

 

 

SELECT

u. Units_№Unit AS Номер_агрегата,

u. Units_idCode_of_unit AS Шифр_агрегата,

(SELECT Name_of_company FROM organisations WHERE idOrganisation = u. idOrganisation) AS Организация,

u. Units_idNumber_of_engine AS Номер_двигателя,

u. Units_Date_of_unit_creation AS Дата_создания_агрегата,

u. Units_First_defect_appearence_since_using_of_unit AS СНЭ_агрегата,

(SELECT Type_of_defect FROM types_of_defect WHERE idType_of_defect = d. idType_of_defect) AS Тип_дефекта,

d. Description_of_defect AS Описание_дефекта

FROM defects d

           INNER JOIN units_has_defects uhd ON d. idDefect = uhd. Defects_idDefect

           INNER JOIN units u ON (

                          uhd. Units_Units_idCode_of_unit = u. Units_idCode_of_unit AND

                          uhd. Units_Units_idNumber_of_engine = u. Units_idNumber_of_engine AND

                          uhd. Units_Units_№Unit = u. Units_№Unit AND

                          uhd. Units_Units_Type_of_units_Manufacturer_organisation_of_unit = u. idOrganisation

);


[1] SELECT, FROM, WHERE – это ключевые (зарегистрированные) слова SQL (их немного)

Поделиться:





Воспользуйтесь поиском по сайту:



©2015 - 2024 megalektsii.ru Все авторские права принадлежат авторам лекционных материалов. Обратная связь с нами...