query oracle database table

Posted on 2012-08-22
Last Modified: 2012-08-24

I am looking for syntax to query oracle database table

select * from XYZ_table where col1='123';

col1 is varchar column.

when I run above query giving invalid number error then says licence is not there error and hanging up Toad.

select * from XYZ_table;

Above query runs fine though.

Any ideas, suggestions, sample code, links, source code highly appreciated. Thanks in advance
Question by:gudii9
    LVL 76

    Accepted Solution

    Try the query from sqlplus not Toad.
    LVL 20

    Assisted Solution

    select * from XYZ_table where col1='123';

    Open in new window

    Syntactically, this is correct. You must have something else going on here - some things you can check:
    - is there a partition on col1
    - does your query work in SQLPlus
    - are there some specific settings on numeric conversions in Toad
    - also, what is the exact error
    - does
    select * from XYZ_table where col1='abc'; -- or some other non-numeric

    Open in new window

    work correctly?
    LVL 37

    Assisted Solution

    by:Gerwin Jansen
    Can you describe the table for us? Use:
    desc XYZ_table;

    Open in new window

    and show the output. Thanks.
    LVL 76

    Expert Comment

    by:slightwv (䄆 Netminder)
    What was the solution?

    Splitting points to everyone doesn't help anyone in the future to solve their issue.
    LVL 37

    Expert Comment

    by:Gerwin Jansen
    Agreed, I see no solution here, this question best be deleted if no answer is given.

    Featured Post

    Do You Know the 4 Main Threat Actor Types?

    Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

    Join & Write a Comment

    Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
    This article describes how to use the timestamp of existing data in a database to allow Tableau to calculate the prior work day instead of relying on case statements or if statements to calculate the days of the week.
    This video explains at a high level with the mandatory Oracle Memory processes are as well as touching on some of the more common optional ones.
    This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.

    745 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    17 Experts available now in Live!

    Get 1:1 Help Now