hi!
??????????????else??????????????sql????????????????Invalid table alias or 
column reference 'u' ??????sql????????'u'????????
CREATE CATALOG `tempo_df_hive_default_catalog` WITH(
    'type' = 'hive',
    'default-database' = 'default'
);
USE CATALOG tempo_df_hive_default_catalog;
CREATE TABLE IF NOT EXISTS `default`.`tempo_blackhole_table` (
   f0 INT
);
insert into cosldatacenter.dw_riginfoparam
select 
c.LARGE_EQUIP_ID,
c.EQUIP_CODE,
c.EQUIP_NAME,
c.ENQUEUE_DATE,
c.SHI_TOTAL_LEN,
c.SHI_TYPE_WIDTH,
c.SHI_TYPE_DEPTH,
case when b.param_cn = '????????' then a.param_value else null end as Moonpool,
case when b.param_cn = '????????' then a.param_value else null end as 
MaxWindvelocity,
case when b.param_cn = '????????????' then a.param_value else null end as 
MaxWaveheight,
case when b.param_cn = '????' then a.param_value else null end as Airgap,
case when b.param_cn = '????????????????' then a.param_value else null end as 
MaxOpeWaterdepth,
case when b.param_cn = '????????????' then a.param_value else null end as 
DrilldepthCap,
case when b.param_cn = '????????????' then a.param_value else null end as 
DrillVL,
case when b.param_cn = '??????' then a.param_value else null end as DrillWater,
case when b.param_cn = '??????' then a.param_value else null end as PotableWater
from cosldatacenter.ods_emp_maindata_iadc_paramvalue a 
inner join cosldatacenter.ods_emp_maindata_iadc_paramdef b on a.param_id = 
b.param_id
inner join cosldatacenter.ods_emp_md_large_equip c on 
a.SUBJECT_ID=c.LARGE_EQUIP_ID;
INSERT INTO `default`.`tempo_blackhole_table` SELECT 1 ;





org.apache.hadoop.hive.ql.parse.SemanticException: Line 2:178 Invalid table 
alias or column reference 'u': (possible column names are: a.paramvalue_id, 
a.platform_id, a.equipment_id, a.param_id, a.param_value, a.remark, 
a.create_time, a.creator, a.update_time, a.update_person, a.record_flag, 
a.subject_id, a.output_unit, a.show_seq, b.param_id, b.iadc_id, b.param_code, 
b.param_en, b.param_cn, b.output_standard, b.output_unit, b.param_type, 
b.param_value, b.remark, b.create_time, b.creator, b.update_time, 
b.update_person, b.record_flag, c.large_equip_id, c.equip_name, c.equip_type, 
c.equip_function, c.equip_board, c.ship_yard, c.manufacturer_date, 
c.enqueue_date, c.dockrepair_date, c.scrap_date, c.enqueue_mode, 
c.work_for_org, c.work_in_org, c.old_age, c.create_time, c.creator, 
c.update_time, c.update_person, c.record_flag, c.data_timestamp, 
c.work_unit_id, c.work_status, c.work_location, c.work_area, c.equip_code, 
c.shi_main_power, c.shi_total_len, c.shi_type_width, c.shi_type_depth, 
c.shi_design_draft, c.shi_total_tonnage, c.shi_load_tonnage, c.remark, 
c.unit_classification1, c.unit_classification2)




------------------ ???????? ------------------
??????:                                                                         
                                               "user-zh"                        
                                                            
<[email protected]&gt;;
????????:&nbsp;2021??7??29??(??????) ????3:32
??????:&nbsp;"user-zh"<[email protected]&gt;;

????:&nbsp;Re: flink 1.13.1 ????hive??????????hive sql????????



????????sql??????????????????ELSE????

??????
Leonard


&gt; ?? 2021??7??27????20:04??Asahi Lee <[email protected]&gt; ??????
&gt; 
&gt; CASE
&gt;            WHEN mipd.`param_cn` = '????????' THEN
&gt;            mipv.`param_value`&amp;nbsp;
&gt;    END AS `Moonpool`

回复