sql question 4.1.1.19.59 of unit test developer

Hello

4.1.1.19 version build HAND - 19.59 I had a problem to run the unit tests with exception as expected result. No matter if I say "ANY" or specify an error number. All the tests fail. Must be a bug.

Oracle SQL Developer  API_OBJEKTARTEN.GetXMLViewName.png

Kind regards.

SQL Developer restarting solves the problem.

Tags: Database

Similar Questions

  • PL/SQL, used in application of the APEX of unit tests

    question by my client:

    I develop an Oracle Application Express application and work on unit tests for stored procedures in PL/SQL and the packages that are stored in the underlying database and used by the application of the APEX. These unit tests must run in the context of SQL Developer Unit Test.
    The problem is that the PL/SQL code stored in the database using functions such as NV('APPLICATION_ITEM') to access items in the application of the apex. They do return all values when I try to execute the PL/SQL within the unit test framework, that is to say in the backend. While it is good that the NV is not error, NULL haven't really work well in my scenario either (for example when the result of this function is inserted into a column NOT NULL in a table). I can think of a few workarounds, such as the creation of my own function NV within the schema to test return values desirable, but nothing seems a really satisfactory solution. I wonder if there is no recommendation to Oracle for this scenario - how can I run code that uses the APEX via backend-specific features. I found nothing in the documentation of the APEX for this but I would like to know if there is a recommendation how to better deal with this case.

    I use SQL Developer version 4.0.0.13.80

    Hello

    Indeed, you must set your PL/SQL function calls. This would be the cleanest solution.

    There is an alternative. Please see the following article on the creation of an APEX in PL/SQL session: Martin Giffy D'Souza on Oracle APEX: how to create a Session of the APEX in PL/SQL

    This approach allows to set the values of APEX application item before you run your unit tests. I don't know if it's possible in SQL Developer Unit Test, but it might get you further down the road.

    Good luck

    Nick

  • the basic sql question

    Hi all I have a basic sql question
    Watch below two querries
    1.  select 1 from dual where 1 in (select 1 from dual union all select null from dual) 
    
    It gives output  as 1
    
    but below one 
    
    2.   select 1 from dual where 1 not in  (select 2 from dual union all select null from dual)
    
    It gives output as no data found 
    I think as operator will not compare with all the values, but not the outcome it will compare with all values... When comparing with the value null, the result is automatically null

    I'm wrong
    Please help me on this

    and why performance wise in operator is more better than no of?

    Thanks to all in advance

    Thanks for posting your explain plan command

    Execution Plan
    ----------------------------------------------------------
    Plan hash value: 3249215828
    
    -----------------------------------------------------------------------------
    | Id  | Operation        | Name     | Rows  | Bytes | Cost (%CPU)| Time     |
    -----------------------------------------------------------------------------
    |   0 | SELECT STATEMENT |          |     2 |     6 |     4   (0)| 00:00:01 |
    |   1 |  NESTED LOOPS    |          |     2 |     6 |     4   (0)| 00:00:01 |
    |   2 |   FAST DUAL      |          |     1 |       |     2   (0)| 00:00:01 |
    |   3 |   VIEW           | VW_NSO_1 |     2 |     6 |     2   (0)| 00:00:01 |
    |   4 |    SORT UNIQUE   |          |     2 |       |     2   (0)| 00:00:01 |
    |   5 |     UNION-ALL    |          |       |       |            |          |
    |   6 |      FAST DUAL   |          |     1 |       |     2   (0)| 00:00:01 |
    |*  7 |      FILTER      |          |       |       |            |          |
    |   8 |       FAST DUAL  |          |     1 |       |     2   (0)| 00:00:01 |
    -----------------------------------------------------------------------------
    
    Predicate Information (identified by operation id):
    ---------------------------------------------------
    
       7 - filter(NULL IS NOT NULL)
    
    02:12:54 SQL> select 1 from dual where 1 not in  (select 2 from dual union all select null from dual);
    Elapsed: 00:00:00.01
    
    Execution Plan
    ----------------------------------------------------------
    Plan hash value: 3291682568
    
    -----------------------------------------------------------------
    | Id  | Operation        | Name | Rows  | Cost (%CPU)| Time     |
    -----------------------------------------------------------------
    |   0 | SELECT STATEMENT |      |     1 |     4   (0)| 00:00:01 |
    |*  1 |  FILTER          |      |       |            |          |
    |   2 |   FAST DUAL      |      |     1 |     2   (0)| 00:00:01 |
    |   3 |   UNION-ALL      |      |       |            |          |
    |*  4 |    FILTER        |      |       |            |          |
    |   5 |     FAST DUAL    |      |     1 |     2   (0)| 00:00:01 |
    |   6 |    FAST DUAL     |      |     1 |     2   (0)| 00:00:01 |
    -----------------------------------------------------------------
    
  • Apex SQL question - weeks of the month

    I have a sql question.
    I want to create a dynamic list.

    If the user select may2009, then I want a dynamic list of show

    04/27/2009-05/03/2009
    05/04/2009-05/10/2009
    05/11/2009-05/17/2009
    05/18/2009-05/24/2009
    05/25/2009-05/31/2009

    If the user selects Jun 2009, then the list will be
    06/01/2009-06/07/2009
    06/08/2009-06/14/2009
    06/15/2009-06/21/2009
    06/22/2009-06/28/2009
    06/29/2009-07/05/2009

    Thank you.

    Using this SQL statement, you can get this list:

    SELECT w_start || ' - ' || w_end d, w_start r
      FROM (SELECT     (week_start_list + (LEVEL - 1) * 7) + 1 w_start,
                       week_start_list + (LEVEL) * 7 w_end
                  FROM (SELECT TO_CHAR (TRUNC (TO_DATE (:my_date, 'dd.mm.yyyy'),
                                               'mm'
                                              ),
                                        'IW'
                                       ) week_begin,
                               TRUNC (TO_DATE (:my_date, 'dd.mm.yyyy'),
                                      'mm'
                                     ) m_begin,
                               TO_CHAR
                                  (TRUNC (TO_DATE (:my_date, 'dd.mm.yyyy'), 'mm'),
                                   'd'
                                  ) day_month_begin,
                               TO_CHAR
                                  (TRUNC (ADD_MONTHS (TO_DATE (:my_date,
                                                               'dd.mm.yyyy'
                                                              ),
                                                      1
                                                     ),
                                          'mm'
                                         ),
                                   'IW'
                                  ) week_end,
                               TRUNC (ADD_MONTHS (TO_DATE (:my_date, 'dd.mm.yyyy'),
                                                  1
                                                 ),
                                      'mm'
                                     ) m_end,
                               TO_CHAR
                                  (TRUNC (ADD_MONTHS (TO_DATE (:my_date,
                                                               'dd.mm.yyyy'
                                                              ),
                                                      1
                                                     ),
                                          'mm'
                                         ),
                                   'd'
                                  ) day_month_end,
                                 TRUNC (TO_DATE (:my_date, 'dd.mm.yyyy'),
                                        'mm'
                                       )
                               - TO_NUMBER
                                          (TO_CHAR (TRUNC (TO_DATE (:my_date,
                                                                    'dd.mm.yyyy'
                                                                   ),
                                                           'mm'
                                                          ),
                                                    'd'
                                                   )
                                          ) week_start_list,
                                 TRUNC
                                    (ADD_MONTHS (TO_DATE (:my_date, 'dd.mm.yyyy'),
                                                 1
                                                ),
                                     'mm'
                                    )
                               + TO_NUMBER
                                    (TO_CHAR
                                        (TRUNC
                                              (ADD_MONTHS (TO_DATE (:my_date,
                                                                    'dd.mm.yyyy'
                                                                   ),
                                                           1
                                                          ),
                                               'mm'
                                              ),
                                         'd'
                                        )
                                    )
                               - 1 week_end_list
                          FROM DUAL)
            CONNECT BY LEVEL <=
                          (SELECT   TO_NUMBER
                                       (TO_CHAR
                                           (TRUNC
                                               (ADD_MONTHS (TO_DATE (:my_date,
                                                                     'dd.mm.yyyy'
                                                                    ),
                                                            1
                                                           ),
                                                'mm'
                                               ),
                                            'IW'
                                           )
                                       )
                                  - TO_NUMBER
                                          (TO_CHAR (TRUNC (TO_DATE (:my_date,
                                                                    'dd.mm.yyyy'
                                                                   ),
                                                           'mm'
                                                          ),
                                                    'IW'
                                                   )
                                          )
                             FROM DUAL))
    

    It is a question of SQL and has nothing to do with the Apex.

    Denes Kubicek
    -------------------------------------------------------------------
    http://deneskubicek.blogspot.com/
    http://www.Opal-consulting.de/training
    http://Apex.Oracle.com/pls/OTN/f?p=31517:1
    -------------------------------------------------------------------

  • Oracle PL SQL Question to get some data to oracle tables descrepancy

    Version of database

    Oracle9i Enterprise Edition Release 9.2.0.8.0 - 64 bit Production
    PL/SQL Release 9.2.0.8.0 - Production
    CORE Production 9.2.0.8.0
    AMT for HP - UX: 9.2.0.8.0 - Production Version
    NLSRTL Version 9.2.0.8.0 - Production

    created a few sample data

    drop table tab1 purge;
    create table tab1 (DEPT_ID COMP, qc_subtype_id char (4), EQUIP_CODE varchar2 (20), create_time date);
    Insert into tab1 values(13,'1026','HEMORYA011',sysdate);
    Insert into tab1 values(13,'1012','HEMORYA011',sysdate);
    Insert into tab1 values(95,'1026','HEMORYA121',sysdate);
    Insert into tab1 values(95,'1012','HEMORYA121',sysdate);
    ----------------------
    Insert into tab1 values(13,'1026','HEMORYA014',sysdate);
    Insert into tab1 values(13,'1012','HEMORYA005',sysdate);
    Insert into tab1 values(13,'1012','HEMORYA013',sysdate);
    Insert into tab1 values(95,'1012','HEMORYA013',sysdate);
    Insert into tab1 values(95,'1012','HEMORYA148',sysdate);

    commit;

    I need to get a query to get the records of the gap

    Dept HEMORYA014 13 lack 1012

    HEMORYA005 dept 12 lack 1026

    Dept HEMORYA013 13 lack 1026

    The dept 95 lack 1026 HEMORYA013

    The dept 95 lack 1026 HEMORYA148

    I want to show the latter on the report

    Thanks in advance.

    Thanks for posting a unit test.
    I hope it will work for you, but maybe you will need to set the WHERE clause (add additional predicates).

    SQL> select equip_code
      2  from ( select equip_code
      3         ,      count(distinct qc_subtype_id)
      4         from   tab1
      5         group by equip_code
      6         having count(distinct qc_subtype_id)<2
      7        )
      8  order by equip_code;
    
    EQUIP_CODE
    --------------------
    HEMORYA005
    HEMORYA013
    HEMORYA014
    HEMORYA148
    
  • Unit test in sql developer 4.1 fails but passes in 4.0

    I can't tell if it's a question of Java or Sql * developer issue.

    SQL * Developer Version: 64-bit 4.1.0.17.29

    Versions of Java: Tried jdk 8: 1.8.0_5, 1.8.0_20 and 1.8.0_31 - all 64 bits

    That is the message in the response of unit test:

    CPS_TOOLS.PREP_FOR_DELIMITED_FIELD failed: Missing defines
    oracle.jdbc.driver.Accessor.isNull(Accessor.java:744)
    oracle.jdbc.driver.CharCommonAccessor.getString(CharCommonAccessor.java:350)
    oracle.jdbc.driver.OracleCallableStatement.getString(OracleCallableStatement.java:661)
    oracle.jdbc.driver.OracleCallableStatementWrapper.getString(OracleCallableStatementWrapper.java:860)
    oracle.jdbc.proxy.oracle$1dbtools$1raptor$1proxy$1driver$1oracle$1RaptorProxyOJDBCStatement$2oracle$1jdbc$1internal$1OracleCallableStatement$$$Proxy.getString(Unknown Source)
    oracle.dbtools.raptor.datatypes.strategies.callablestatement.CallableBindingVARCHAR.customOutputByPosition(CallableBindingVARCHAR.java:51)
    oracle.dbtools.raptor.datatypes.strategies.callablestatement.CallableBindingDatumAtName.customOutput(CallableBindingDatumAtName.java:123)
    oracle.dbtools.raptor.datatypes.impl.CallableBindingImpl.getOutput(CallableBindingImpl.java:74)
    oracle.dbtools.unit_test.testObjects.UtTestImplArgs.getOutput(UtTestImplArgs.java:320)
    oracle.dbtools.unit_test.runner.Runner.executeRunn ...
    
    
    

    Now, the same unit test works with the following text:

    SQL * Developer Version: 64-bit 4.0.2.15

    The Versions of Java: 64 bit jdk 7 - 1.7.0_55

    I tried to follow here debug information collection:

    http://www.thatjeffsmith.com/archive/2012/06/how-to-collect-Debug-Info-for-Oracle-SQL-Developer/

    However, there is no report in the command window after a ctrl-pause/break. At the same time, however, it is not like sql * developer hangs here.

    Thoughts?

    EA 4.1 includes a new feature to save all JDBC calls (view > Log, and then note the statements tab in the logs pane), so it could be the difference in the behavior of Test Unit between 4.0 and 4.1.

    You use the JDBC default 12.1 driver, or you have overridden by specifying a particular Oracle client?  In other words, in

    Tools > Preferences > Database > advanced > use Oracle client > configure...


    I read that somewhere there may be problems when you use the clients pre - 12 c with earlier versions of JDBC. driver

  • Is there a real BENEFIT in SQL * Developer Automated Unit Testing?

    I'm trying to understand the unit test in SQL * Developer. Asked me to evaluate it as a method of test automation on an integration solution that we develop.

    (1) my 'A' schema has this table:

    SQL > DESC EMP

    Name                                      Null?    Type

    ----------------------------------------- -------- --------------------

    EMPID NOT NULL NUMBER

    EMPNAME VARCHAR2 (30)

    SALARY NUMBER (7.2)

    COMM_PCT NUMBER (2.2)

    Table (2). has these values:

    SQL > SELECT * from emps;

    EMPID EMPNAME SALARY COMM_PCT

    ---------- ---------- ---------- ----------

    1 ROHAN 10000.05

    2 JOHN 20000

    3 PETER.06

    4 SMITH

    (3.) I create this procedure in drive A:

    create or replace

    PROCEDURE award_bonus (NUMBER, sales_amt NUMBER p_empid)

    AS

    REAL Commission;

    comm_missing EXCEPTION;

    BEGIN

    SELECT comm_pct IN the commission OF EMP

    WHERE empid = p_empid;

    IF the commission IS NULL THEN

    RAISE comm_missing;

    ON THE OTHER

    PGE UPDATED

    SET salary = salary + sales_amt * commission

    WHERE empid = p_empid;

    END IF;

    END award_bonus;

    (4) now, I want to create a unit test in SQL Developer to test this procedure.

    (5) I created a user "unit_test_repos" according to the instructions in the tutorial.

    (6) ' SELECT OPERATION': I specifies the procedure of award_bonus.

    (7) ' SPECIFY the name of test': give a name and select "create with a single model.

    (8.) 'SPECIFY the STARTUP': Add a ' copy Table or the line "the startup process.

    -I give "EMP" as the source table.

    -And then I get this for the 'generated query.

    SELECT ROWID AS SRC$ ROWID, s.* FROM EMP s

    -Target table has "TMP$ AWARD_BONUS.

    (Q1) WHAT IS THE PURPOSE OF CREATING ANOTHER TABLE?

    (Q2) WHEN THE TEST IS DONE, ARE ROWS OF PGE copied into this table?

    (Q3) Why is this? Why can't the test simply read 'EMP '?

    (9) "PARAMETERS SPECIFY": I give "Input".

    -1 for P_EMPID

    -10000 for SALES_AMT

    -In "Expected result", I say "success."

    (Q4) So I should know in my mind the results of the proc, foregoing given entries?

    (10) ' SPECIFY VALIDATION': I add validation "poll rows of queries.

    -I paste the following query: SELECT count (*) FROM EMP WHERE empid = 1 AND salary = 10500

    -that is, I know that for an amount of 10000 sales, employee 1 will get a Commission of 10000*.05 = 500. For example, 10000 (its sal) + 500 = 10500.

    (Q5) The thought that the above is correct?

    (11) "TEARDOOWN SPECIFY": give nothing.

    (12) my unit test is created.

    (13.) I run now by clicking on the button of the beetle, to the left of the green arrow. Unit test is run.

    (14) now in my table a.emps, 1 salary has increased to 10 500, and the diag test case, I get the "execution results: SUCCEED.

    (15) now, I run the unit test again.

    (16.) salary 'EMP' table emp 1 is passed to 11000 (which is correct) and the so-called execution results "SUCCESS".

    (Q6)  My question is: the query I gave for validation, SELECT count (*) FROM EMP WHERE empid = 1 AND = 10500 salary, now gives 0. so, this means that no row is returned for this condition and so the test must FAIL. But how is SQL * Developer said that the test was SUCCESSFUL. How does this system of validation?

    (17.) I went through the tutorial, but I do not understand these concepts >

    (Q7) What is the purpose of disassembly? I undersand the option 'drop table' "disassembly", where you drop the temporary table, but I do not understand the others, 'Table or line restore' and 'code pl/sql user '?

    (Q8) WHAT IS the advantage of making the test like this? Can I use an Excel spreadsheet and make dozens of unit tests faster than this method?  It is easy to understand too. This method is complicated.

    Your answers and your advice would be greatly appreciated.

    The temporary table to hold the original values for EMP. After the test runs, you must configure the disassembly to reset the return values of the temporary for the next time table that the test works again, he has values of expected start.

  • Unit testing: why white spaces are added to the PL/SQL lines on each edition?

    Dear team of SQL Developer,

    Are you aware of this very annoying problem of the unit test is running: a space is added to each line of PL/SQL code with each unit test that is run?

    The length of each line of code continues to grow with each race...

    I wonder why is it and you have an existing reference to bug for this... Please let me know...

    Thank you

    Val

    Thank you, Gary!

    The bug was just connected:

    BUG 20061594 - UNIT TESTS: the UNWANTED SPACE CHARACTERS ADDED to THE SQL CODE

    I've updated the SR that white spaces are added after each change, and that it can be easily mistaken for each run (we open the editor for see/check, or simply to do an update before a new race), but the bug has already been created with a description of the problem of evil:

    "...

    Description of the problem

    ===================

    Spaces are added after each line of SQL in the Unit Test after each race. »

    Sorry about that... I hope that the bug will be updated with correct description before you guys accept it as a bug:

    "...

    Description of the problem

    ===================

    Spaces are added after each line of SQL in the Unit Test after each change. »

    Thanks again,

    Val

  • Question of unit tests

    Hi all

    Creating the Unit Test case for a procedure or a function with a PL/SQL table as an input/output setting, the system throws an error "the return type table is not supported.

    Why is it so? Pointers?

    Thank you

    Anand

    The unit test supports only the SQL types, no type of PL/SQL. There is no reference to it in the documentation.

  • Developer SQL 3 EA1: Unit Test

    Hello

    I just started to use the work unit test framework in SQL Developer 3 EA 1 and I need assistance, definition of a test case involving parent - child tables that are handled using an API from plsql. The API for the child table requires a registration key in the parent table. The parent record and its key is created by a process of starting test case. The key is retrieved using a query of dynamic value in the implementation of the test. It seems that the dynamic value query is executed before the start of the test case process have been executed. Is this expected behavior? My expectation is that the boot process are executed before the dynamic values query.

    Also, is it possible to use values resulting from processes of startup as the case other than type parameter values by using a dynamic query in value?

    Summary test scenario:

    2 boot process: the first deletes all the data tables parent and the child. The second inserts in a record in the parent table.

    No disassembly process.

    Test implementation: application of dynamic value that selects the key of the parent table and defines literals for the remaining parameters of test cases.

    1 process validation: check if a record has been inserted into the table of childe with expected values.

    Thank you

    Alistair

    Hi Alistair.

    We execute the dynamic query to control how many times the test (start, test cases, validation, demolish) cycle runs.

    To get the behavior you want, put the test in a test suite and test suite start do the initialization of the table for you.

    Brian Jeffries
    SQL development team

  • SQL Developer 3.0 EA 1 Advanced support for the type of data in the unit tests

    Hello

    According to SQL Developer 3.0 EA 1 New Feature List (http://www.oracle.com/technetwork/developer-tools/sql-developer/rel3-featurelist-ea1-166831.html#ut)
    the EA 1 version 3.0 supported advanced data types in the unit tests. This means support the ANYDATA and RECORD types? I installed version 3.0 of EA 1 to CentOS linux, but it seems that those advanced types are not supported yet. When I try to add a unit test for a function that returns the record type, I get quick error: "the return of PL/SQL RECORD type is not supported. Cannot test (function_name) because 1 arguments have not supported for types". Also if I try to unit test procedure which parameter is of type ANYDATA, I get quick error: "the type UNDEFINED P_DATA argument is not supported. Cannot test (procedure_name) because 1 arguments have not supported for types". Are those advanced data types supported in SQL Developer 3.0 FINAL version?

    Thank you
    Miikka L

    Edited by: user12844253 the 27.10.2010 16:31

    Hi Mikka,

    Only simple PL/SQL records are currently supported i.e. those containing no optional or repeating components and where all components are themselves supported. This restriction is in place, due to the fact that we are using JDBC as a parameter mechanism which does not directly support the passage the PL/SQL record type.

    ANYTYPE and ANYDATA are currently not supported because they have a dynamic value type and must be set programmatically. In the future, it would be possible to support these via the dynamic value and and validation features.

    This will remain for the final version.

    Kind regards
    Richard

  • SQL question on natural joins

    I am a newbie to SQL and I studied the book of Fundamentals SQL Server Oracle OCA 12 c, but a section on natural joins to confuse me.

    Basically, the author says:

    SELECT r.region_name, d.department_name, l.city, c.country_name

    DEPARTMENTS d

    NATURAL JOIN places l, c countries, regions r;

    The natural join between DEPARTMENTS and LOCATIONS creates a provisional result, consisting of 27 lines since they are implicitly attached on the column of location_id. This set is then Cartesian-joined to the table of the COUNTRY as a join condition is not implicitly or explicitly specified. 27 interim lines are attached to 25 lines in the COUNTRY table, which gives a new temp results set with 675 (27 × 25) rows and three columns: DEPARTMENT_NAME, CITY and COUNTRY_NAME. This set is then attached to the REGION table. Once more, a Cartesian join occurs because column REGION_ID is absent from any join condition. The final result set contains rows and four columns (675 × 4) 2700.

    I can understand because you evaluate joins from the left. But then he wrote:

    The JOIN... USE and JOIN... ON the syntaxes are better suited to join multiple tables. The following query joins four tables using the natural join syntax:

    SELECT country_id region_id, c.country_name, l.city, d.department_name

    DEPARTMENTS d

    NATURAL JOIN places l

    NATURAL JOIN country c

    NATURAL JOIN region r;

    This query generates correctly 27 lines in the final results set since the required join columns are listed in the SELECT clause. The following query illustrates how the JOIN... CLAUSE is used to extract the same 27 lines. A join condition can reference columns only in its scope. In the following example, the join of DEPARTMENTS slots can not reference columns in the COUNTRIES or REGIONS of tables, but the join between the COUNTRIES and REGIONS may refer to any column of four tables involved in the query.

    This second method of the part of the natural writing joined confuses me. I don't understand the logic behind the 2nd series of States of Natural Join. For me, it seems that the first series and the 2nd set look alike, but they are apparently not.

    Can someone tell me the differences?

    Thank you!!

    Hello

    The more important thing to learn more about NATURAL JOIN is: never use it.  If you add new columns, joins can get different results.  I've never heard of someone uisng NATURAL JOIN apart from a manual or a question like yours.

    There are a lot of things in Oracle that take the time to learn and are useful.  All the time you spend learning things is better spent on them.

  • SQL * PLUS connects with SQL &gt; question

    People,

    I'm confused on the command. / sqlplus with Oracle database.

    According to my understanding,. / sqlplus connected with SQL > using option 3: sysdba, sysoper, sysasm.

    I connect with SQL > to run the rel853.sql script to create a table PSOPRDEFN but a field "OPERPSWDSALT" did not appear in the table PSOPRDEFN although it is in the Create Table statement.

    I connect with SQL * in the directory/home/user/OracleDB_Home/bin as below:


    $ export SYSTEM_PASS = AccessId/mypass

    $ export ORACLE_HOME = / home/user/OracleDB_Home

    $ export ORACLE_SID = HRCS90

    $. / lsnrctl start LISTENER

    $. / AccessId/mypass sqlplus as sysdba

    SQL > startup

    SQL > @/opt/PT8.53/scripts/rel853.sql

    SQL > select OPERPSWDSALT in the AccessId.PSOPRDEFN;

    It returns: "OPERPSWDSALT": invalid identifier.


    I checked the table PSOPRDEFN that the OPERPSWDSALT field did not appear in the table PSOPRDEFN.

    I tried the sysoper option as below:

    $. / sqlplus AccessId/mypass as sysoper

    SQL > startup

    SQL > @/opt/PT8.53/scripts/rel853.sql

    SQL > select OPERPSWDSALT in the AccessId.PSOPRDEFN;

    It returns: "OPERPSWDSALT": invalid identifier.

    The sysoper error is the same thing with sysdba error.

    I tried the sysasm option as below:

    $. / sqlplus AccessId/mypass as sysasm

    He returned: connection refused.


    Someone told me this connection as SYS causes this error. If not a sysdba, sysoper, or sysasm, use the command. / sqlplus AccessId/mypass cannot connect with SQL >.


    My question is:


    First of all, why is what OPERPSWDSALT did not appear in the PSOPRDEFN table while it is in the CREATE TABLE statement?


    Seocond, if not use SYS which is one of the 3 options, how to run the command. / sqlplus AccessId/mypass to connect with SQL > so that CREATE TABLE PSOPRDEFN correctly?

    Thank you.

    user8860348 wrote:

    People,

    Hello. Thanks much for the reply. I just do the commands below:

    $ export SYSTEM_PASS = AccessId/mypass

    $ export ORACLE_HOME = / home/user/OracleDB_Home

    $ export ORACLE_SID = HRCS90

    $. / lsnrctl start LISTENER

    $. / AccessId/mypass sqlplus as sysdba

    SQL > show user;

    Its release: the USER is "SYS".

    SQL > connect AccessId/mypass

    Its output:

    Error: ORA - 01034:ORACLE not available

    ORA-27101: shared memory realm does not exist

    64 - Linux_x86 error: no such file or directory.

    As we see above, unable to connect to the Oracle database AccessId.

    My question is:

    What to do on AccessId, so that it can connect to the Oracle database?

    Thank you.

    so much for the use that you refuse to actually use COPY it PASTE & so that we can see the whole session.

    In the past, you did

    > SQL > startup

    Maybe the database is out of order & must be started.

    do exactly as below (line by line)

    ID

    sqlplus

    / as sysdba

    startup

    connect AccessId/mypass

    COPY the results from above then PASTE all back here

  • running of SQL question

    Hi expert,


    When I ran after SQL, error message reads "table or view does not exist" pointing to the table "dba_tab_cols" and "dba_all_tables". There is no other question for this statement, because if I changed table "user_tab_cols" and "user_all_tables", it works well.


    declare
    v_old_table DBA_tab_columns.table_name%type;
    v_where Varchar2 (4000);
    Boolean v_first_col: = true;
    type rc is ref cursor;
    c rc;
    v_rowid varchar2 (20);
    Val varchar2 (50): = "Test note";

    Start
    for r in)
    Select
    t.*
    Of
    dba_tab_cols t, dba_all_tables a
    where t.table_name = a.table_name
    and t.data_type like '% CHAR % '.
    and a.owner = 'QA'
    order by t.table_name loop)

    If v_old_table is null then
    v_old_table: = r.table_name;
    end if;

    If v_old_table <>r.table_name then
    v_first_col: = true;

    -dbms_output.put_line ('search' | v_old_table);

    Open c for ' select rowid from ' ' |. ' v_old_table | '" ' || v_where;

    extract the c in v_rowid;
    loop
    When the output c % notfound;
    dbms_output.put_line (' rowid: ' | v_rowid |) "in" | v_old_table);
    extract the c in v_rowid;
    end loop;

    v_old_table: = r.table_name;
    end if;

    If v_first_col then
    v_where: = 'where ' | r.column_name | "as" %' | Val | '%''';
    v_first_col: = false;
    on the other
    v_where: = v_where | "or" | r.column_name | "as" %' | Val | '%''';
    end if;

    end loop;
    end;


    But if I choose these DBA tables in the toad sql Editor, it works well, I am currently using my own credentials, not the administrator credentials. why he get different effects running in these two ways?

    Thank you very much

    >

    Hello

    When I ran after SQL, error message reads "table or view does not exist" pointing to
    Table 'dba_tab_cols' and 'dba_all_tables '. There is no other question for this statement, because

    If I changed table "user_tab_cols" and "user_all_tables", it works well.
    But if I choose these DBA tables in the toad sql Editor, it works well, I am currently using my own
    credentials, not the administrator credentials. why he get different effects running in these two ways?

    You answered your own question - you know that you have the administrator privileges when you
    Open a session under your own credentials - but your id user obviously does TOAD.

    You use SQL * for the query that fails?

    BTW, you do not give us your version of Oracle - you must always tell us what it is

    Please read the forum FAQ and also the thread "sticky" by BluShadow at the top of the list of positions
    on the forum homepage. These forums are an excellent resource - you will get the best out of them if
    you follow the instructions.

    HTH,

    Paul...

    Published by: Paulie July 24, 2012 16:40

  • SQL question to get a top customer of the page

    Hi all
    I'm prasanna. I have a question about SQL, to get a customer based on name of the year and the customer. I wrote the request like this. But I got an error.

    Select calendar_year, cust_first_name, max (sum (amount_sold)) in sale, the time the customers where sales.cust_id = customers.cust_id and times.time_id = sales.time_id of the calendar_year group, cust_first_name

    The error is like this:

    * Error from the 1 in the command line:
    Select calendar_year, cust_first_name, max (sum (amount_sold)) in sale, the time the customers where sales.cust_id = customers.cust_id and times.time_id = sales.time_id of the calendar_year group, cust_first_name
    Error in the command line: 1 column: 7
    Error report:
    SQL error: ORA-00937: not a function of simple-group
    00937 00000 - 'not a single-group function. "
    * Cause:
    Action:

    Thank you inadvace
    Kind regards
    Prasanna

    865016 wrote:
    Your response, I had only one top customer with year, name of the client, amount_sold. But I need for each year

    select  calendar_year,
            cust_first_name,
            total_amount_sold max_amount_sold
      from  (
             select  calendar_year,
                     cust_first_name,
                     sum(amount_sold) total_amount_sold,
                     row_number() over(partition by calendar_year order by sum(amount_sold) desc) rn
               from  sales,
                     times,
                     customers
               where sales.cust_id=customers.cust_id
                 and times.time_id=sales.time_id
               group by calendar_year,
                     cust_first_name
            )
      where rn = 1
    / 
    

    I will give you a single customer by calendar_year.

    SY.

Maybe you are looking for

  • Save the settings of AirPort Utility in the cloud

    I'm looking in the purchase of some Airport extreme or time Capsules. Can I configure the settings for them on a Mac and then these parameters record to the App on my iPhone or the AirPort Utility program on another Mac?

  • 4472 sampling finished

    Hi all I use a 4472 to take a sample done with a digital reference falling edge triggering. The sample per channel is set to x and the pre-trigger amount is 90 %x. Now we start taking data using the StartTask (task_handle) in LabWindows/CVI. Suppose

  • Acer Aspire switch 11, how to turn off the click left tap?

    Well, starting the touchpad already has the feature where you click on it, it records the left click of the mouse each time you do. There is absolutely no need "tap to the left of the mouse" option, it is completely redundant and very annoying.

  • I'm trying to understand why there is no sound to my pc

    where can find audio drivers for windows xp sc3

  • Cannot find my wireless router

    IM so confused, im of the problems with my wireless router, when I connected my nintendo wii, that it worked fine, so I decided to make a secure connection by giving a password and other then on the pc finds the router, I made a password for wireless