Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I would like to confirm the following with respect to the basic SQL Queries:

  1. The float and real data types cannot be used with the equals and not equals operator in sql. If so then what else operators can i use for these data types.

  2. Filtering based on the BLOB and XML columns is not allowed. So shall we disable any search based on these datatypes, also is there any other data type that cannot be filtered from the sql query?

[edit] 3. Also what kind of operators can i use for the timestamp data type.

share|improve this question

1 Answer 1

up vote 4 down vote accepted
  1. Untrue. You can use them but the "approximate" nature means they could be unreliable.
    Use range queries (BETWEEN etc) or use decimal

  2. If you use the max types (text, image etc are deprecated) then you can CAST or SUBSTRING etc as needed to search and filter
    For XML you can search using XQuery
    Note: a binary BLOB that is a word document or such can not be searched in SQL Server

  3. Never tried any. timestamp (deprecated, use rowversion) isn't designed to be manipulated
    Unless you mean datetime which as datetime functions

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.