I need to select all rows where a specific character is in the column. SQL Server 2005

Posted on 2007-10-08
Last Modified: 2010-03-19
I need to select all rows where a specific character is in the column.

This obviously does not work
SELECT * FROM SymbolTable  WHERE 'b' IN SymbolName

Question by:Dovberman
    LVL 61

    Expert Comment

    SELECT * FROM SymbolTable  WHERE SymbolName = 'b'
    LVL 92

    Assisted Solution

    by:Patrick Matthews
    SELECT * FROM SymbolTable  WHERE SymbolName LIKE '%b%'
    LVL 75

    Accepted Solution

    another option

    SELECT * FROM SymbolTable  WHERE CHARINDEX('b',SymbolName) > 0

    Featured Post

    What Security Threats Are You Missing?

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Join & Write a Comment

    'Between' is such a common word we rarely think about it but in SQL it has a very specific definition we should be aware of. While most database vendors will have their own unique phrases to describe it (see references at end) the concept in common …
    Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
    Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
    This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

    733 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