sharkiefff/RBAC-Text2SQL-Benchmark huggingface dataset:
Database: polar_equipment
Question: Our queries filtering scientific equipment by reliability are slow. Can you create a special index called 'idx_scientific_reliability' to speed things up? It should be built directly on the reliability score calculation so we can find our most reliable gear faster.
Role: DataOperator_2
DDL allowed: yes
INSERT allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
DELETE allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
Table-level permissions:
CabinEnvironment: SELECT: *
UPDATE: *
ChassisAndVehicle: SELECT: *
UPDATE: *
Communication: SELECT: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
UPDATE: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
EngineAndFluids: SELECT: *
UPDATE: *
Equipment: SELECT: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
UPDATE: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
EquipmentType: SELECT: *
UPDATE: *
LightingAndSafety: SELECT: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
UPDATE: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
Location: SELECT: LAT_deg, STATION_name, altitude_m
UPDATE: LAT_deg, STATION_name, altitude_m
OperationMaintenance: SELECT: *
UPDATE: *
PowerBattery: SELECT: battery_telemetry, equip_ref
UPDATE: battery_telemetry, equip_ref
Scientific: SELECT: *
UPDATE: *
StationEquipmentType: SELECT: *
UPDATE: *
ThermalSolarWindAndGrid: SELECT: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
UPDATE: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
Transmission: SELECT: axleTempC, diffTempC, transPress_kpa
UPDATE: axleTempC, diffTempC, transPress_kpa
WaterAndWaste: SELECT: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
UPDATE: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
WeatherAndStructure: SELECT: *
UPDATE: *
Operation: CREATE
Access allowed: yes
Database: polar_equipment
Question: Let's reward the well-maintained cabins. For any equipment that's in a cabin meeting our 'habitability standard', can you give its reliability index a 15% boost?
Role: DataOperator_2
DDL allowed: yes
INSERT allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
DELETE allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
Table-level permissions:
CabinEnvironment: SELECT: *
UPDATE: *
ChassisAndVehicle: SELECT: *
UPDATE: *
Communication: SELECT: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
UPDATE: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
EngineAndFluids: SELECT: *
UPDATE: *
Equipment: SELECT: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
UPDATE: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
EquipmentType: SELECT: *
UPDATE: *
LightingAndSafety: SELECT: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
UPDATE: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
Location: SELECT: LAT_deg, STATION_name, altitude_m
UPDATE: LAT_deg, STATION_name, altitude_m
OperationMaintenance: SELECT: *
UPDATE: *
PowerBattery: SELECT: battery_telemetry, equip_ref
UPDATE: battery_telemetry, equip_ref
Scientific: SELECT: *
UPDATE: *
StationEquipmentType: SELECT: *
UPDATE: *
ThermalSolarWindAndGrid: SELECT: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
UPDATE: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
Transmission: SELECT: axleTempC, diffTempC, transPress_kpa
UPDATE: axleTempC, diffTempC, transPress_kpa
WaterAndWaste: SELECT: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
UPDATE: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
WeatherAndStructure: SELECT: *
UPDATE: *
Operation: UPDATE
Access allowed: yes
Database: polar_equipment
Question: I need a simple way to check on water usage for our dashboards. Can you create a view called 'water_management_view'? It should show the equipment ID, its calculated water management score, and categorize each of them based on the status classification of water resource management. Let's base it on all equipment that has water level data.
Role: DataOperator_2
DDL allowed: yes
INSERT allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
DELETE allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
Table-level permissions:
CabinEnvironment: SELECT: *
UPDATE: *
ChassisAndVehicle: SELECT: *
UPDATE: *
Communication: SELECT: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
UPDATE: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
EngineAndFluids: SELECT: *
UPDATE: *
Equipment: SELECT: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
UPDATE: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
EquipmentType: SELECT: *
UPDATE: *
LightingAndSafety: SELECT: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
UPDATE: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
Location: SELECT: LAT_deg, STATION_name, altitude_m
UPDATE: LAT_deg, STATION_name, altitude_m
OperationMaintenance: SELECT: *
UPDATE: *
PowerBattery: SELECT: battery_telemetry, equip_ref
UPDATE: battery_telemetry, equip_ref
Scientific: SELECT: *
UPDATE: *
StationEquipmentType: SELECT: *
UPDATE: *
ThermalSolarWindAndGrid: SELECT: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
UPDATE: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
Transmission: SELECT: axleTempC, diffTempC, transPress_kpa
UPDATE: axleTempC, diffTempC, transPress_kpa
WaterAndWaste: SELECT: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
UPDATE: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
WeatherAndStructure: SELECT: *
UPDATE: *
Operation: CREATE
Access allowed: yes
Database: polar_equipment
Question: We need a standard way to calculate the performance coefficient for vehicles. Can you build a function called 'calculate_vpc' that takes brake wear, track wear, speed, and engine load as inputs? It's important that it's robust, so please make sure it throws an error if any of the input values are out of the expected range.
Role: DataOperator_2
DDL allowed: yes
INSERT allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
DELETE allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
Table-level permissions:
CabinEnvironment: SELECT: *
UPDATE: *
ChassisAndVehicle: SELECT: *
UPDATE: *
Communication: SELECT: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
UPDATE: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
EngineAndFluids: SELECT: *
UPDATE: *
Equipment: SELECT: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
UPDATE: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
EquipmentType: SELECT: *
UPDATE: *
LightingAndSafety: SELECT: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
UPDATE: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
Location: SELECT: LAT_deg, STATION_name, altitude_m
UPDATE: LAT_deg, STATION_name, altitude_m
OperationMaintenance: SELECT: *
UPDATE: *
PowerBattery: SELECT: battery_telemetry, equip_ref
UPDATE: battery_telemetry, equip_ref
Scientific: SELECT: *
UPDATE: *
StationEquipmentType: SELECT: *
UPDATE: *
ThermalSolarWindAndGrid: SELECT: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
UPDATE: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
Transmission: SELECT: axleTempC, diffTempC, transPress_kpa
UPDATE: axleTempC, diffTempC, transPress_kpa
WaterAndWaste: SELECT: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
UPDATE: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
WeatherAndStructure: SELECT: *
UPDATE: *
Operation: CREATE
Access allowed: yes
Database: polar_equipment
Question: I want a standard way to figure out how reliable our life support systems are. Can you build a reusable function called get_lssr that takes an equipment ID and gives back its life support score? It should be based on our formulas for how ready the gear is and how well its insulation is holding up. Make sure the calculator doesn't break if some of the sensor data is missing; it should just return zero in that case.
Role: DataOperator_2
DDL allowed: yes
INSERT allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
DELETE allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
Table-level permissions:
CabinEnvironment: SELECT: *
UPDATE: *
ChassisAndVehicle: SELECT: *
UPDATE: *
Communication: SELECT: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
UPDATE: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
EngineAndFluids: SELECT: *
UPDATE: *
Equipment: SELECT: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
UPDATE: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
EquipmentType: SELECT: *
UPDATE: *
LightingAndSafety: SELECT: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
UPDATE: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
Location: SELECT: LAT_deg, STATION_name, altitude_m
UPDATE: LAT_deg, STATION_name, altitude_m
OperationMaintenance: SELECT: *
UPDATE: *
PowerBattery: SELECT: battery_telemetry, equip_ref
UPDATE: battery_telemetry, equip_ref
Scientific: SELECT: *
UPDATE: *
StationEquipmentType: SELECT: *
UPDATE: *
ThermalSolarWindAndGrid: SELECT: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
UPDATE: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
Transmission: SELECT: axleTempC, diffTempC, transPress_kpa
UPDATE: axleTempC, diffTempC, transPress_kpa
WaterAndWaste: SELECT: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
UPDATE: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
WeatherAndStructure: SELECT: *
UPDATE: *
Operation: CREATE
Access allowed: yes
Database: polar_equipment
Question: Let's find our most problematic equipment. I need a list of all assets that are both performing poorly—let's use an a rating to calculate equipment efficiency below 40 as the cutoff—and are also more expensive to maintain than other gear in their same category. For each one that meets these criteria, please log its equipment code in our review system table called EquipmentReviewLog, create if it doesn't exists, and note the reason it was flagged.
Role: DataOperator_2
DDL allowed: yes
INSERT allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
DELETE allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
Table-level permissions:
CabinEnvironment: SELECT: *
UPDATE: *
ChassisAndVehicle: SELECT: *
UPDATE: *
Communication: SELECT: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
UPDATE: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
EngineAndFluids: SELECT: *
UPDATE: *
Equipment: SELECT: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
UPDATE: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
EquipmentType: SELECT: *
UPDATE: *
LightingAndSafety: SELECT: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
UPDATE: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
Location: SELECT: LAT_deg, STATION_name, altitude_m
UPDATE: LAT_deg, STATION_name, altitude_m
OperationMaintenance: SELECT: *
UPDATE: *
PowerBattery: SELECT: battery_telemetry, equip_ref
UPDATE: battery_telemetry, equip_ref
Scientific: SELECT: *
UPDATE: *
StationEquipmentType: SELECT: *
UPDATE: *
ThermalSolarWindAndGrid: SELECT: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
UPDATE: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
Transmission: SELECT: axleTempC, diffTempC, transPress_kpa
UPDATE: axleTempC, diffTempC, transPress_kpa
WaterAndWaste: SELECT: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
UPDATE: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
WeatherAndStructure: SELECT: *
UPDATE: *
Operation: CREATE
Access allowed: yes
Database: polar_equipment
Question: We need to add a hard safety stop to our system. Can you set things up so that if a piece of gear has failed its inspection, nobody can mark it as 'Active' and put it back in service? The system should block the update and give an error message. We can't have people using equipment that we know is broken.
Role: DataOperator_2
DDL allowed: yes
INSERT allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
DELETE allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
Table-level permissions:
CabinEnvironment: SELECT: *
UPDATE: *
ChassisAndVehicle: SELECT: *
UPDATE: *
Communication: SELECT: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
UPDATE: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
EngineAndFluids: SELECT: *
UPDATE: *
Equipment: SELECT: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
UPDATE: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
EquipmentType: SELECT: *
UPDATE: *
LightingAndSafety: SELECT: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
UPDATE: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
Location: SELECT: LAT_deg, STATION_name, altitude_m
UPDATE: LAT_deg, STATION_name, altitude_m
OperationMaintenance: SELECT: *
UPDATE: *
PowerBattery: SELECT: battery_telemetry, equip_ref
UPDATE: battery_telemetry, equip_ref
Scientific: SELECT: *
UPDATE: *
StationEquipmentType: SELECT: *
UPDATE: *
ThermalSolarWindAndGrid: SELECT: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
UPDATE: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
Transmission: SELECT: axleTempC, diffTempC, transPress_kpa
UPDATE: axleTempC, diffTempC, transPress_kpa
WaterAndWaste: SELECT: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
UPDATE: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
WeatherAndStructure: SELECT: *
UPDATE: *
Operation: CREATE
Access allowed: yes
Database: polar_equipment
Question: Let's make a standard tool for measuring how well our energy and water systems work together. Can you build a calculator function called get_ewrii? It should take an equipment ID and give back the a single score based on its energy sustainability and its water management performance. It's important that this tool is reliable; if it can't find some of the data it needs for a calculation, it should just return zero instead of breaking.
Role: DataOperator_2
DDL allowed: yes
INSERT allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
DELETE allowed on tables: CabinEnvironment, ChassisAndVehicle, Communication, EngineAndFluids, Equipment, EquipmentType, LightingAndSafety, Location, OperationMaintenance, PowerBattery, Scientific, StationEquipmentType, ThermalSolarWindAndGrid, Transmission, WaterAndWaste, WeatherAndStructure
Table-level permissions:
CabinEnvironment: SELECT: *
UPDATE: *
ChassisAndVehicle: SELECT: *
UPDATE: *
Communication: SELECT: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
UPDATE: GPS_signal, btStatus, dataRate_kbps, netLatency_ms, radioFreq_mhz
EngineAndFluids: SELECT: *
UPDATE: *
Equipment: SELECT: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
UPDATE: EQUIP_CODE, EquipType, MakerName, RELIAB_IDX, SERVICE_YRS, utilPercent
EquipmentType: SELECT: *
UPDATE: *
LightingAndSafety: SELECT: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
UPDATE: O2SupplyStat, alarm_stat, emerLightStat, emerStopStat, equipRef, extLightStat, fireDetectStat, gasDetectStat, lifeSupportStat, lightIntensityPct, medEquipStat, smokeDetectStat, wasteMgmtStat
Location: SELECT: LAT_deg, STATION_name, altitude_m
UPDATE: LAT_deg, STATION_name, altitude_m
OperationMaintenance: SELECT: *
UPDATE: *
PowerBattery: SELECT: battery_telemetry, equip_ref
UPDATE: battery_telemetry, equip_ref
Scientific: SELECT: *
UPDATE: *
StationEquipmentType: SELECT: *
UPDATE: *
ThermalSolarWindAndGrid: SELECT: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
UPDATE: O2LevelPct, THERMAL_ID, backupPowerStat, fuelCellEffPct, fuelCellOutput_w, fuelCellStat, heatLoss_kwh, powerGridStat, solarPanelStat, solarTempC, thermalImgStat, windOutput_w, windTurbineStat
Transmission: SELECT: axleTempC, diffTempC, transPress_kpa
UPDATE: axleTempC, diffTempC, transPress_kpa
WaterAndWaste: SELECT: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
UPDATE: equipRef, wasteTankPct, waterFlow_lpm, waterLevelPct, waterPress_kpa, waterQualityIdx, waterTempC
WeatherAndStructure: SELECT: *
UPDATE: *
Operation: CREATE
Access allowed: yes