NULL COLLATION IN ORACLE 8
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 3 of 3

Thread: NULL COLLATION IN ORACLE 8

Hybrid View

  1. #1
    Join Date
    Jul 2000
    Posts
    3
    IS THERE ANY WAY TO TRIGGER LOW COLLATION OF NULLS IN ORACLE (Maybe an environment variable). eg. select * from table order by column2 - where table contains 3 records:
    A NULL
    A XXXX
    B NULL

    displays:

    A XXXX
    A NULL
    B NULL

    but required order is (As per INFORMIX):
    A NULL
    A XXX
    B NULL

    NOTE: Obviously this is a simplified case
    autouser

  2. #2
    Join Date
    Oct 2000
    Posts
    13
    Remember Oracle is a Relational Data Base, this means, quering data from a table does not retrieve always same order, so if you query 100 times a table, maybe you get 99% times same order and just 1% any others and that is OK.

  3. #3
    Join Date
    Feb 2001
    Posts
    123
    Try order by col1, nvl(col2, low_value)

    In your example, if it is character data, then the lowest value is 'a', so use

    order by col1, nvl(col2, 'a')

    HTH

    David.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width