sql - ORA-00936: missing expression Oracle Query error -


whats wrong query :

select b.doing_biz_as,   lpad(b.rtl_loc_id, 7, '0') str_hdr_loc_id,   lpad(b.store_city,13) str_hdr_city,   lpad(b.state,2) str_hdr_state,   lpad(b.store_pcode,5) str_hdr_pcode,   lpad(b.phone_number, 12) str_hdr_pno,   lpad(sum(a.item_cnt),7,'0') str_tlr_itemcnt,   lpad(sum(a.dr_amt),11,'0') str_tlr_dramt,   lpad(sum(a.cr_amt),7,'0') str_tlr_cramt signtr_sch01.signtr_trans_hdr a,   signtr_sch01.signtr_rtl_loc b a.rtl_loc_id = b.rtl_loc_id , a.rtl_loc_id   = 1984 

at least, group by clause missing.

select b.doing_biz_as,   lpad(b.rtl_loc_id, 7, '0') str_hdr_loc_id,   lpad(b.store_city,13) str_hdr_city,   lpad(b.state,2) str_hdr_state,   lpad(b.store_pcode,5) str_hdr_pcode,   lpad(b.phone_number, 12) str_hdr_pno,   lpad(sum(a.item_cnt),7,'0') str_tlr_itemcnt,   lpad(sum(a.dr_amt),11,'0') str_tlr_dramt,   lpad(sum(a.cr_amt),7,'0') str_tlr_cramt signtr_sch01.signtr_trans_hdr a,   signtr_sch01.signtr_rtl_loc b a.rtl_loc_id = b.rtl_loc_id , a.rtl_loc_id   = 1984 group b.doing_biz_as,          b.rtl_loc_id,          b.store_city,          b.state,          b.store_pcode,          b.phone_number 

Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -