Where am I missing my illegal variable name/number

I am updating a program that I created some time ago and set different levels of access based on a flag in a column. Now when I run the new version, I get variable name/number errors ORA-01036 occasional illegal in one of the functions.

The code in question (where the only change occurred in this section) is:

string l6Str = "SELECT email, leo FROM jc_hc_users_dev WHERE oof='F' AND id IN (SELECT usr_id FROM jc_hc_usr_snd_dev WHERE loi_id=:loiid OR grp_id=:grpid)"; OracleCommand l6Cmd = new OracleCommand(l6Str, lCxn); l6Cmd.Parameters.Add("loiid", OracleType.Int32).Value = L2id; l6Cmd.Parameters.Add("grpid", OracleType.VarChar).Value = l2GrpId; // if the reader is populated with email addresses, add them into a List for sending. using (OracleDataReader l6Rdr = l6Cmd.ExecuteReader()) { if (l6Rdr.HasRows) { while (l6Rdr.Read()) { if (l6Rdr["leo"].ToString() == "F") { CivEmails.Add(l6Rdr["email"].ToString()); } else { BccEmails.Add(l6Rdr["email"].ToString()); } } } }

The loiid parameter is a Number (10,0) table and the: grpid is Varchar2 (10).

Or is the problem in the l6Rdr ["leo"]. ToString() and l6Rdr ['email']. ToString() part?

Thanks in advance for any help!

I don't think that the problem is in the code from the outside. I guess that's probably on the query.

Please, make sure that all values that are joined correspond to the data type:

Number 4 and number (6) do not cause the error.

can you show me the errors with the ORA-01036? Have you tried to reproduce the query in sqlplus? Maybe you can get more information...

Tags: Database

Similar Questions

  • ORA-01506: missing or illegal database name

    I can't start the database instead, I get the above error. Help, please

    [oracle@localhost /] $ pwd
    /
    [oracle@localhost /] $ cd/u01/app/oracle
    [oracle@localhost oracle] $ export ORACLE_BASE = / u01/app/oracle
    [oracle@localhost oracle] $ export ORACLE_HOME=/u01/app/oracle/product/11.2.0/dbhome_1
    [oracle@localhost oracle] $ export ORACLE_SID = orcl
    [oracle@localhost oracle] $ export PATH = $ORACLE_HOME/bin: $PATH
    [oracle@localhost oracle] $ export TNS_ADMIN=/u01/app/oracle/product/11.2.0/dbhome_1/network/admin
    [oracle@localhost oracle] $ sqlplus / as sysdba

    SQL * more: Production of release 11.2.0.1.0 Thu Feb 14 17:33:11 2013

    Copyright (c) 1982, 2009, Oracle. All rights reserved.

    Connect to an instance is idle.

    SQL > startup
    ORA-01506: missing or illegal database name
    SQL >

    >
    ...
    [oracle@localhost oracle] $ export ORACLE_SID = orcl
    ...
    -rw - r - r - 1 root root 69 14 Feb 12:02 initorcl.ora
    ...
    >

    Why the initorcl.ora file is owned by root? As mentioned, do not perform any oracle about actions or commands as root.

    HTH
    Srini

  • illegal variable name.

    What is illegal lhere. I don't understand.
    declare
      -- Non-scalar parameters require additional processing 
      i_terminaloutofloop t_general_numlist;
      i_currentterminalonloop t_general_numlist;
      currterminalid number:=1178050;
      res number;
    begin
      i_terminaloutofloop:=t_general_numlist(1178050);
      i_currentterminalonloop:=t_general_numlist(1177797);
      -- Call the function
      res := pkgapi.cntdisturbr( i_currterminal =>   currterminalid,
                                            i_terminaloutofloop => i_terminaloutofloop,
                                            i_currentterminalonloop => i_currentterminalonloop);
                                            dbms_output.put_line(  res );
    end;

    This is a pl/developer test script. check if all the variables are in the bottom panel.
    Amiel Davis.

    Published by: Amiel d. April 15, 2010 22:57

  • Get the string variable name in PL/SQL

    Hello
    Strange question. Is there a way to have access to the object of a decision of the variable IN the name in a procedure?

    for example.
    procedure (var1    IN VARCHAR2(6),
                    var2    IN VARCHAR2(6),
                    var3    IN VARCHAR2(6))
    
    IS....
    You run this procedure and pass in parameters to:

    var1 = > "abcdef"
    var2 = > "defghi",.
    var3 = > 'ghikjl ';

    In the code, I want to access the number in the string of the + variable name: var1+.

    In a naïve sense,.
    num_of_in_var := substr(var1, 4,1) 
    would I hoped to achieve, but

    var1 is set to 'abcdef' if so,
    num_of_in_var := substr(var1, 4,1) 
    would return was '.

    Any thoughts?

    Thank you

    Published by: chris001 on November 20, 2012 13:16

    Hi Chris,

    You can find the details of the $user_arguments data dictionary view settings.

    select argument_name from user_arguments where object_name = 'PROCEDURE_NAME';
    
  • Get the bind variables name string SQL or the cursor

    Hello

    Is there way to get of the bind variables name string SQL or the cursor?

    Example of
    DECLARE
      l_sql VARCHAR2(2000);
      desctab DBMS_SQL.DESC_TAB;
      curid   PLS_INTEGER;
    BEGIN
    
      l_sql := 'SELECT * FROM emp WHERE mgr = :X and deptno = :Y';
    
      curid := dbms_sql.open_cursor;
      dbms_sql.parse(curid, l_sql, dbms_sql.NATIVE);
      ....
    END;
    What I mean with the SQL string:
    I love to get using some functions from above code variable l_sql all the bind variable.
    In this case the function should return array where is for example: X and: Y

    Back to bind the cursor variable names, I mean same but rather string I pass number of cursor.

    Y at - it sucks ready function or some may share a code customized for this purpose?

    Thanks

    Kind regards
    Jari

    http://dbswh.webhop.NET/dbswh/f?p=blog:Home:0Regards,

    Published by: jarola December 19, 2011 02:44

    I found there are wwv_flow_utilities.get_binds of the function not documented in APEX packages that do what I want.
    Usage example
    set serveroutput on
    DECLARE
      binds DBMS_SQL.varchar2_table;
    BEGIN
      binds := wwv_flow_utilities.get_binds('select :P1_TEST from dual');
      FOR i IN 1 .. binds.count
      LOOP
        dbms_output.put_line(binds(i));
      END LOOP;
    END;
    /
    
    anonymous block completed
    :P1_TEST
    But I would not use these functions without papers as those who can change or there is no future versions APEX.
    Is there a documented function or the custom function that do the same thing as wwv_flow_utilities.get_binds?

    Some old basic example code of my friends. Also the media getting the bind variable of PL/SQL code blocks anon.

    SQL> create or replace function GetBindVariables( statement varchar2 ) return TStrings is
      2          --// bind variables names are terminated by one the following special chars
      3          SPECIAL_CHAR    constant TStrings := TStrings(' ',')','+','-','>','<','*',',','=',';',CHR(10),CHR(13));
      4
      5          --// max size of a bind var name
      6          MAX_VARSIZE     constant integer := 100;
      7
      8          pos     integer;
      9          pos1    integer;
     10          occur   integer;
     11          varName varchar2(100);
     12          varList TStrings;
     13  begin
     14          varList := new TStrings();
     15
     16          --// looking for the 1st occurance of a bind variable
     17          occur := 1;
     18
     19          loop
     20                  pos := InStr( statement, ':', 1, occur );
     21                  exit when pos = 0;
     22
     23                  varName := SubStr( statement, pos, 100 );
     24
     25                  --// find the terminating char trailing the
     26                  --// bind variable name
     27                  pos1 := Length( varName );
     28                  for i in 1..SPECIAL_CHAR.Count
     29                  loop
     30                          pos := InStr( varName, SPECIAL_CHAR(i) ) - 1;
     31                          if (pos > 0) and (pos < pos1) then
     32                                  pos1 := pos;
     33                          end if;
     34                  end loop;
     35
     36                  --// extract the actual bind var name (without
     37                  --// colon char prefix)
     38                  varName := SubStr( varName, 2, pos1-1 );
     39
     40                  --// maintain a unique list of var names
     41                  if not varName member of varList then
     42                          varList.Extend(1);
     43                          varList( varList.Count ) := varName;
     44                  end if;
     45
     46                  --// look for the next occurance
     47                  occur := occur + 1;
     48          end loop;
     49
     50          return( varList );
     51  end;
     52  /
    
    Function created.
    
    SQL>
    SQL> select
      2          column_value as BIND_VAR
      3  from TABLE(
      4          GetBindVariables('select * from foo where col=:BIND1 and day = to_date(:B2,''yyyy/mm/dd'')')
      5  );
    
    BIND_VAR
    ------------------------------
    BIND1
    B2
    
    SQL> 
    

    PS. just realize this code is case-sensitive, while variable bind is not. Should throw a upper() or lower() by adding the name of the var to the list - never really a problem for me because I'm pretty tense when it use cases correctly in the code. ;-)

    Published by: Billy Verreynne, December 19, 2011 06:19

  • Add a variable name?

    I use one for a loop to creat a bunch of identical clips.  I want to join a different sound to each of these clips.  Is it possible to add a variable to the end of another variable name.  (ie. where I = [0,1,2,3,4, etc.] variable [i] = variable1, variable2, variable3, variable4, variable0, etc..)  Here is the part of the code I'm trying to make it work:

    for (var i:Number = 0; i < xmlData.object_count; i++){
    
            //create movie clips
            var boxContainer_mc:boxContainer = new boxContainer();
            addChild(boxContainer_mc);
            boxContainer_mc.x = 325 * i;  // set the number here to the width of the movie clip being repeated
            
            //sound info
            var snd[i]:Sound = new Sound();
            snd[i].load(new URLRequest("creak128.mp3"));
            boxContainer_mc.addEventListener(MouseEvent.CLICK, playSound, false, 0, true);
    
            function playSound(event:MouseEvent):void {
                snd[i].play();
            }
        }
    

    The NDS is what I'm trying to add with the County I.

    If you see this message once, it is one of these url loop for which do not exist.

    and you must never nest named functions and playSound shouldn't be in a loop for.

  • Adding dynamic text; How can I stop the projection variable name?

    I create a simple game for children.  On the first page, I added a "text input" field for his first name.  I called the firstname variable.

    When they move to the next page, I used a 'text dyanamic' field so I can call by name on this page.  This works.  However, when I test the game, on the first page, where the first name is entered, it shows the _level0.firstname instead of just a blank for them to enter their name.

    I know I've fixed this in the past and it was something simple, but I don't remember how to do it.  I would be grateful to anyone who helps!

    Thank you.

    do not assign a variable name for the textfield object. or, at least, do not use the same name of the textfield variable and instance name.

  • display variable &lt; variable name &gt; does not work

    Hello

    I use 11.1.2.2 Essbase version and I want to export a specific substitution to txt variable trust,.

    I used the command "Display the variable" and it works if I use the following syntax:

    variable display;

    < application > variable display;

    Display variable on < database >;

    but it does not work when I use a syntax to export a single variable:

    display variable < variable name; >

    Looks like the error message: ERROR - 1051083 - Substitution variable < variable name > does not exist.

    Of course, the variable exists in the server.

    I hope that someone will have an idea of what is wrong,

    Thank you

    Yuval

    Unless it's a variable substitution at the server level, it would need to be fully qualified, for example if you have a 'Test' associated with Sample.Basic variable, you must:

    display variable Sample.Basic.Test;

    ... not...

    display variable Test;

  • I get error filter Render - error in initialization of symmetry script: line 43: Variable name expected. Help, please.

    Hi all

    I left creative cloud. Check the updates.

    That an activity that could affect system files was to uninstall applications CC, keeping the CC 2014 apps only.

    I need to use the flame of rendering filter, but I get the following error

    Error in the initialization of symmetry script: line 43: Variable name expected

    I get this error with tree to make and restore frame.

    A response will be appreciated

    Thank you

    Thank you for your response. I just came back good. After making sure that I got all the updates, I quit and restarted photoshop and it does the trick.

  • Question related to the requirement of since 11.1.1.5 uppercase variable names

    Hello

    I recently upgraded from 11.1.1.3 to 11.1.1.6 version of ODI.

    I had a few problems of running packages that worked on 11.1.1.3. I figured out it was the variable case question.

    I have a lot of procedures in my project, where I'm passing lower cased variable of command on the source of command on the target.

    For example

    Command on the target:

    OdiStartScen-SCEN_NAME = PACKAGE1-SCEN_VERSION =-1 - LOG_LEVEL = #log_level-GLOBAL. V_HOST = #host - GLOBAL. V_PORT = #port

    Command on the source:

    Select the host, port, log_level < % = odiRef.getObjectName ("TABLE") % >


    I tried to use double quotes, it didn't work. Then I wrote all the variables at the top of case (OdiStartScen-SCEN_NAME = PACKAGE1-SCEN_VERSION =-1 - LOG_LEVEL = #LOG_LEVEL-GLOBAL.) V_HOST = #HOST - GLOBAL. V_PORT = #PORT) and it worked.

    Now I have a big project on my hands, with a large number of procedures.

    Is there a solution to automate the process?

    Love, looking for a certain string (log_level, host...) in each of the control of each procedure throughout the project and replace it with the capital letter? Maybe the Jython script?

    It would save me a lot of time. Help, please.

    Thanks for you effort in advance!

    It was a bug (12971227) on 11.1.1.6.0 and there is a patch available to fix the problem. Please apply the patch that contains the fix for the bug 12971227 in your environment.

  • Is there a telephone number where I can call someone? The phone number in your web page is missing a num

    Is there a telephone number where I can call someone? The phone number in your web page is missing a number. It is listed as 1-800-426-570? A number of missing. I just paid with my credit card in line for photoshop and it does not allow me to connect to download.

    You can use the link https://helpx.adobe.com/utilities/credit-card.html top of page updated following card details & inform me by message private.

    It will be updated.

    Or you can contact the Adobe Support via http://adobe.ly/yxj0t6

    Concerning

    Baudier

  • After Effects customize template with web browser? (name of the layer by giving a variable name)?

    After Effects customize template with web browser? (name of the layer by giving a variable name)?

    so many web sites provideing this service... .online at the intro

    Please help me what plugins using. How to set up this kind of service?

    I think that we should move to an AE forum...

  • Function call for the ActionScript variable name

    I am tempted to call a function dynamically by using a string variable.  I know that to do this normally, I would use code like this:

    var functionName:String = '' + currentItem.id;

    var myData:Array = this [functionName] (parameter1, parameter 2, parameter3);

    However, my function is actually in another directory of flex/package called UploadApps.customUploadFunctions.  I tried this sort of thing:

    var functionName:String = '' + currentItem.id;

    var myData:Array = UploadApps.customUploadFunctions.this [functionName] (parameter1, parameter 2, parameter3);

    but it does not work.  Any ideas on how to call a function with a variable name in another package?

    John

    My suggestion is to stop using the methods at the level of the package. Just do static methods in a utility class as we do in the framework in the mx.utils package. Then you can easily call them UtilityClassName [functionName] (param1, param2, param3). Given that the programming in AS3 is 99.9% on classes, I don't know why AS3 allows even the methods package level.

    Gordon Smith

    Adobe Flex SDK team

  • Using the definition of a variable as a variable name

    I have a string variable with the definition that I use as a variable name.

    For example, it is super simple:

    var newVariable = 'it's working. "
    var partOne:String = "new";
    var partTwo:String = "Variable";
    var partThree = partOne + partTwo;

    trace ("my variable is" + partThree);

    Instead of tracing partThree literally partOne + partTwo (which traces "newVariable"), I would like to trace the definition of partOne + partTwo (which is 'it works').

    I hope this makes sense, help or advice is appreciated.

    ...
    ...
    var partThree = this partOne [+ partTwo];

    trace ("my variable is" + partThree); will the traces: my variable is it works

    TS

  • Use a variable name in a function?

    Here's my function...

    myInterval = setInterval (TTMO, 15);

    function TTMO () {}
    InstanceNameOfMovieClip._x = (InstanceNameOfMovieClip._x - _xmouse) / 10;
    InstanceNameOfMovieClip._y = (InstanceNameOfMovieClip._y - _ymouse) / 10-2;
    }

    Can I use a variable name instead of using the "InstanceNameOfMovieClip"? I tried, but it does not work. I also tried to use the correct hierarchy, as this ._parent. VariableName too.

    you have to concat the link with the movieclip using your variable of string like this

    var mcName_str = "bigBox_mc";

    This [mcName_str] ._x = 20;

    You can use this method to loop through the objects named in an incremental way

    for (var i: Number = 0; i<>
    {
    This ["mc" + i] ._x = 20;
    }

    hope that helped

Maybe you are looking for

  • Is there a way in which I can see if Apple firewall blocks the traffic to a certain IP address?

    Connection to my e-mail domain seems to be blocked by a body between my home network (via Apple AirPort) and my mail server to an external service provider. I can connect to this fine through my mobile operator, but not from my home network. This lea

  • 5 v TTL-Trigger for audio output

    Hi all as the title says, I would use a 5 V TTL-relaxation to start at the exit of a sound signal. The 5 V TTL-Trigger is generated by a camera after the capture an image and send to a USB Port. I would like to as LabView to recognize each of these i

  • My CPU usage is 100%, SVCHOST stable. EXE uses all CPUS, why?

    On rare occasions, my CPU usage is less than 25%.  My computer is running very slowly.

  • Given the run around by Tech Support

    I initially contacted Dell technical support on February 6, 2016. I was told that the problem I saw with the GPU means the tech must be returned for repair. After 5 weeks to be passed around between different support groups and fill in many forms of

  • Windows 7, re - install

    Original title: Mr Keith Morton Hello I bought a laptop from a 2nd hand one year hold. Its a machine retailers [PC World I think] an advent Roma 2000 Windows 7 sticker on it & the COA on background [badly worn / illegible], but for windows 7. I had p