表达式“ <表达式>”不能用作分配目标

时间:2018-09-21 09:19:24

标签: oracle plsql

在此过程中,我在COALESCE函数上遇到了错误:

  

[错误] PLS-00363(1091:30):PLS-00363:表达式''不能用作分配目标。

我应该将哪个参数声明为out或in out?...我尝试了o_max_bet,o_min_bet,o_max_win,但是错误是相同的...

以下是整个过程:

   PROCEDURE open_session_3w (
      i_player_id              NUMBER,
      old_session_id           NUMBER,
      i_ip_address             VARCHAR2,
      i_machine_number         VARCHAR2,
      o_last_bet         OUT   NUMBER,
      o_min_bet         in out   NUMBER,
      o_max_bet          in out  NUMBER,
      o_max_win         in out  NUMBER,
      o_credits          OUT   NUMBER,
      o_session_id       OUT   NUMBER,
      o_state            OUT   VARCHAR2
   )
   IS
      o_percentage       NUMBER;   
      o_pot              NUMBER;                           
      pom                weak_cur;
      p_active_session   NUMBER;
      p_parent           number;
      v_max_win           number;
      v_min_bet           number;
      v_max_bet           number;
   BEGIN
     select parent_id into p_parent from casino_users where party_id = i_player_id;
      check_pl_sess_3w (i_player_id, old_session_id);
      o_session_id :=

     player.open_new_session (i_player_id, i_ip_address,i_machine_number,'GAME SESSION');

 select MAX( CASE WHEN gp.name = 'MAX_WIN' THEN VALUE END ),
           MAX( CASE WHEN gp.name = 'MAX_BET' THEN VALUE END ),
           MAX( CASE WHEN gp.name = 'MIN_BET' THEN VALUE END )
    INTO v_max_win,v_max_bet,v_min_bet
          FROM   game_definition_aff gda,
         GAME_PARAMETAR gp,
         game_aff ga,
         game_name gn    
         WHERE   i_player_id = ga.aff_id 
          AND   ga.id = gda.game_aff_id
          AND   gp.id = gda.game_parametar_id
          AND   15 = ga.game_name_id
          AND   gn.game_name_id = ga.game_name_id
          and gp.name in ( 'MIN_BET','MAX_BET','MAX_WIN') ;

      player.get_percentage (i_player_id,
                             o_session_id,
                             royal_tri_win,
                             o_percentage,
                             COALESCE(v_min_bet,o_min_bet),
                             COALESCE(v_max_bet,o_max_bet),
                             COALESCE(v_max_win,o_max_win),
                             o_pot
                            );
    .
    .
    .

end open_session_3w ;   


PROCEDURE get_percentage (i_player_id NUMBER, i_session_id NUMBER, i_game_id NUMBER, o_percentage OUT NUMBER, o_min_bet OUT NUMBER, o_max_bet OUT NUMBER, o_max_win OUT NUMBER, o_pot OUT NUMBER)

0 个答案:

没有答案