【正文】
here isnumeric(sale_price)=1(C)上面的檢查通過后再將tempitem中處理后的數(shù)據插入到t_bd_item_info中通過觸發(fā)器生成相應數(shù)據, 注意t_bd_supcust_item要手動去生成,如客戶有需要則幫他們生成下Insert into t_bd_item_info(item_no,item_subno,item_name,item_subname,item_clsno,main_supcust,price,sale_price) select * from tempitem. 捆綁商品表商品檔案相應字段:bine_sta = 39。 )另注意不要把供應商設置成0供應商,有時候客戶倒入倒出的時候會刪除掉這個供應商select * from tempitem where main_supcust=39。 or main_supcst is null檢查供應商編號是否存在select distinct(main_supcust) from tempitem where main_supcust not in(select supcust_no from t_bd_supcust_info where supcust_flag=39。 where main_supcust=39。 or main_supcust is null處理供應商編號為空的商品,修改成自行添加的一個供應商tempsuptempsup是我們自行增加的用來處理臨時的無供應商商品update tempite