Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Easy question on LONG fields
Sean <dolans_at_my-deja.com> wrote in message
news:8c8egh$2ho$1_at_nnrp1.deja.com...
> I am trying to optimize our design and hopefully have a simple
> question. What are the performance "drains" on doing a query on a LONG
> field? The design of the record can either be:
> A VARCHAR2(2000)
> B VARCHAR2(2000)
> C VARCHAR2(2000)
> ... etc...
>
> Or I can make it:
> A LONG
>
>
> I do understand the restrictions I put on myself when I design the
> first way and see the benefits of having it in a LONG.
>
> I hear on the newsgroups occasionally about the overhead incurred on a
> LONG. Can anyone speak to that?
>
> Thanks for the help. (and apologies for the simplicity of the question)
>
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
Which version of the database are you using. If Oracle 8 and upwards you
should use a CLOB.
If Oracle 7, there are many, many limitations
- only one long per table
- functions on a long are NOT allowed, hence you can't use substr, instr,
etc.
So, if the info in the LONG can be split up in three distinct columns, I
wouldn't use a LONG.
My experience tells me it is always more easy to concatenate than to
extract.
I would use a LONG only for truly binary data, and data that doesn't need to
manipulated and searched on.
Hth,
Sybrand Bakker, Oracle DBA Received on Sun Apr 02 2000 - 17:27:32 CDT
![]() |
![]() |