Re: Copying longs in Perl
Date: Tue, 6 Oct 2009 06:34:21 +1100
Sure this is possible. The trick is to set the LongReadLen attribute before you create the statement handle. I usually do it in two steps - first select the max length of the long column and save into a variable. Then, use the value of that variable in setting the LongReadLen attribute before creating the statement handle that fetches the data. You will probably also want to set the RowCacheSize attribute to 1 so that you don't grab too much memory.
Let me know if you need any more detail.
On 06/10/2009, at 6:18 AM, Jason Heinrich wrote:
> I have a perl script that manages audit data, and one of the things
> it does is create a copy of the sys.aud$ table in a separate
> tablespace for archiving purposes. I'm attempting to add the
> sys.fga_log$ table to this script so I can manage the fine-grained
> audit data as well, but it contains a long column so I can't just do
> a "create table as select" or I'll get an ORA-00997. The standard
> answer to this problem is to use the copy command in sqlplus, but
> I'd prefer to keep the code in perl. Is this possible?
> Jason Heinrich
This email is intended solely for the use of the addressee and may contain information that is confidential, proprietary, or both. If you receive this email in error please immediately notify the sender and delete the email. Received on Mon Oct 05 2009 - 14:34:21 CDT