5 Replies Latest reply: Jan 2, 2013 9:22 AM by 982153 RSS

    Queries in SQL developper do not return anything?

    982153
      Hello there,

      First of I am completely new to Oracle and IT in general. Apart from having used computers since the heyday my knowledge of programming is very little. I have been reading Oracle documentation and bought the CBT nuggets tutorials to prepare for examination.

      I have followed the instructions to install the HR schema which worked in SQL*Plus but whenever i go into SQL developper and create a connection using the same username/password as I did in SQL*plus, then type in the select table_name from user_tables; query, nothing happens.

      What am I doing wrong? Am i simply not connecting to the same DB?

      Thanks in advance
        • 1. Re: Queries in SQL developper do not return anything?
          Mukesh75
          first test the connection.
          if success then write the query and check in query result pane.
          • 2. Re: Queries in SQL developper do not return anything?
            982153
            What do you mean by test the connection? In SQL developer it 'connects' to the database which has the same password as I used to log into SQL PLus.
            I made a new connection called HR in SQL developer with the username System and same password.
            • 3. Re: Queries in SQL developper do not return anything?
              Jim Smith
              You need to be logged in as HR.

              "Select * from user_tables" returns the tables owned by the current user and system doesn't own any tables.
              • 4. Re: Queries in SQL developper do not return anything?
                982153
                So when i set up the HR schema using SQL plus and was prompted to give a password for HR, i did that. Now when i open up the SQL plus (as administrator) and log in using username HR and the password i set for it, I can access the Schema's default tables such as employees.

                However on SQL developper, I open up a new connection called HR and put the same password that HR uses on SQL plus but whenever I attempt a select statement there are no returns. It just seems like SQL developper is not connected to the database.

                I am currently using the CBT nuggers tutorial for the fundamentals exam 1z0-051 and the tutorial uses both SQL developer and SQL plus.

                I appreciate all the responses but unfortunately I am stuck :(

                I get this message when i go to Query builder:

                Text is not a valid, single SELECT statement.
                Syntax Error at line 4, column 9


                select * employees;
                ^^^

                Expected: ',','BULK','FROM','INTO',BULK_COLLECT_opt,from_clause,into_list,
                Query Builder disabled.

                Edited by: Vlakarmis on Jan 2, 2013 7:04 AM
                • 5. Re: Queries in SQL developper do not return anything?
                  982153
                  Sorry guys I finally figured it out. I had the message log opened and thus could not see that actually the queries were being returned. MY apologies and thank you for your help :)