There appears to be a small bug w.r.t. displaying object types when they are selected in a SQL window.
Set up in a command window:
Then run this query in a SQL window:
Note that in the first 13 columns (those corresponding with "t.img") the values are incorrect starting at "img.height":
The correct values can be seen in the last 7 columns, which select the attributes directly:
Set up in a command window:
Code:
create table ordimage_test as select ORDSYS.ORDImage.init() img from dual;
declare
l_img ORDSYS.ORDImage;
begin
select img into l_img from ordimage_test for update;
dbms_lob.open(l_img.source.localData, dbms_lob.lob_readwrite);
dbms_lob.writeappend(l_img.source.localData, 40, HEXTORAW('47494638396108000800800100FF0000FFFFFF2C0000000008000800000207848FA9CBED5D00003B'));
dbms_lob.close(l_img.source.localData);
l_img.setProperties();
update ordimage_test set img = l_img;
commit;
end;
/
Then run this query in a SQL window:
Code:
select t.img, t.img.height, t.img.width, t.img.contentlength, t.img.fileformat, t.img.contentformat, t.img.compressionformat, t.img.mimetype
from ordimage_test t;
Note that in the first 13 columns (those corresponding with "t.img") the values are incorrect starting at "img.height":
Code:
IMG.SOURCE.LOCALDATA <BLOB>
IMG.SOURCE.SRCTYPE
IMG.SOURCE.SRCLOCATION
IMG.SOURCE.SRCNAME
IMG.SOURCE.UPDATETIME 6/7/2012 12:13:30 PM
IMG.SOURCE.LOCAL 1
IMG.HEIGHT -9.8089302020202E125
IMG.WIDTH -9.8089302020202E125
IMG.CONTENTLENGTH -9.8086602020202E125
IMG.FILEFORMAT
IMG.CONTENTFORMAT GIFF
IMG.COMPRESSIONFORMAT 1BITLUTRGB
IMG.MIMETYPE GIFLZW
The correct values can be seen in the last 7 columns, which select the attributes directly:
Code:
IMG.HEIGHT 8
IMG.WIDTH 8
IMG.CONTENTLENGTH 35
IMG.FILEFORMAT GIFF
IMG.CONTENTFORMAT 1BITLUTRGB
IMG.COMPRESSIONFORMAT GIFLZW
IMG.MIMETYPE image/gif