0

I can achieve the connection to my oracle database. I have no problem to obtain a table from the base with the query:

SELECT * FROM TABLE1

but when i write:

SELECT * , COLUMN1 FROM TABLE1

it shows error:

in .verify.JDBC.result(r, "Unable to retrieve JDBC result set for ", : Unable to retrieve JDBC result set for select *; column1 FROM Table1 (ORA-00911: carácter no válido )

Any suggestions?

2
  • Assuming you already have COLUMN1 in your resultset, can you try like: select *,COLUMN1 as mynewcolumn from table1 Commented May 16, 2019 at 19:42
  • no, i try this but it not be useful Commented May 16, 2019 at 19:51

1 Answer 1

2

Use a table alias, e.g.

This doesn't work (as you already know it):

SQL> select *, dname from dept;
select *, dname from dept
        *
ERROR at line 1:
ORA-00923: FROM keyword not found where expected

But this works OK:

SQL> select d.*, d.dname from dept d;

    DEPTNO DNAME          LOC           DNAME
---------- -------------- ------------- --------------
        10 ACCOUNTING     NEW YORK      ACCOUNTING
        20 RESEARCH       DALLAS        RESEARCH
        30 SALES          CHICAGO       SALES
        40 OPERATIONS     BOSTON        OPERATIONS

SQL>
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.