Difference between LOB and NTEXT

  • Hi All,

    I would like to know the problems that are being faced while converting a procedure from Oracle to SQL Server.

    I basically work on Oracle Platform.

    There are a few queries i would like to know...

    1) Size of the NTEXT in SQL SERVER

    2) Can there be more than 1 ntext column in a single table.

    3) Precautions to be taken while converting a datatype of LOB into NTEXT.

    4) What if i want to insert or update the column of ntext datatype.

    5) Can i have indexes on columns of ntext.

    6) Is there any default initilization that is to be done for ntext datatype.

    7) Can we treat ntext column as foreign key and join with other tables.

    Can you please update the info i require ASAP. It would be of great help for me.

    Thanks

    Shri 

  • Look up BOL (Books online) - you'll find almost all questions answered there...here's a sampling from BOL..

    ntext
    
    Variable-length Unicode data with a maximum length of 230 - 1 (1,073,741,823) characters. Storage size, in bytes, 
    is two times the number of characters entered. The SQL-92 synonym for ntext is national text.
    
    These functions and statements can be used with ntext, text, or image data.
    
    Functions/Statements 
    DATALENGTH  
    READTEXT 
    PATINDEX 
    SET TEXTSIZE 
    SUBSTRING 
    UPDATETEXT 
    TEXTPTR 
    WRITETEXT 
    TEXTVALID 
    
    If an ntext, text, and image data value is no longer than a Unicode, character, or binary string (4,000 characters, 
    8,000 characters, 8,000 bytes respectively), the value can be referenced in SELECT, UPDATE, and INSERT statements 
    much the same way as the smaller data types. For example, an ntext column with a short value can be referenced in a 
    SELECT statement select list the same way an nvarchar column is referenced. Some restrictions that must be observed, 
    such as not being able to directly reference an ntext, text, or image column in a WHERE clause. These columns can be 
    included in a WHERE clause as parameters of a function that returns another data type (such as ISNULL, SUBSTRING or 
    PATINDEX) or in an IS NULL, IS NOT NULL, or LIKE expression.
    







    **ASCII stupid question, get a stupid ANSI !!!**

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply