Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: About LONG data type: How to read LONG fileds when link two same tables?

Re: About LONG data type: How to read LONG fileds when link two same tables?

From: sybrandb <sybrandb_at_gmail.com>
Date: 19 Dec 2006 01:10:22 -0800
Message-ID: <1166519422.036967.32980@t46g2000cwa.googlegroups.com>

On Dec 19, 8:39 am, "kiluyar" <kilu..._at_gmail.com> wrote:
> Hi, all
> I'm developping an application. I have a table which has a "LONG"
> column. I need to run such sql by OCI:
>
> SELECT "TEST_LONG"."CONTENT", "TEST_LONG_1"."CONTENT"
> FROM "GUEST"."TEST_LONG" "TEST_LONG" INNER
> JOIN "GUEST"."TEST_LONG" "TEST_LONG_1"
> ON "TEST_LONG"."ID"="TEST_LONG_1"."ID"
>
> The TEST_LONG_1 is an alias of TEST_LONG. The CONTENT is a "LONG"
> datatype column.
> However, after executed the sql, I found that when reading rowset, the
> data returned is not correct.
>
> For example, the TEST_LONG has such data:
> ID CONTENT
> 1 A
> 2 B
>
> I get such result after execute:
> CONTENT CONTENT
> A B
>
> It seems after I read out "A" for first column of rowset, I can not
> read "A" again. The first read of second column return "B" directly.
> I don't know how to process this case. The problem is very urgent !
> Would you like to give some advises? Thank you! Thank you very much!

New applications should use LOBs instead of LONGs. LONGs have been deprecated in the previous milennium.
The constraints surrounding LONG don't exist in LOBs. For new applications, especially homegrown, there can be no business reason for LONGs.
Stop using LONGs!

-- 
Sybrand Bakker
Senior Oracle DBA
Received on Tue Dec 19 2006 - 03:10:22 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US