Sponsored Content
Top Forums Shell Programming and Scripting More time to retrieve data from DB Post 302538142 by pattamuthu on Tuesday 12th of July 2011 12:25:17 AM
Old 07-12-2011
More time to retrieve data from DB

Hi All,

It takes around one hour to retrieve 3 lakhs data from DB. I feel this can be still more reduced, please help me in improvising the below code, to get it retrieve faster, atleast 30 to 45 minutes.

Code:
sqlplus -s ${OCAU_DB_UNAME}/${OCAU_DB_UPSWD}@${OCAU_DB_NAME} > /apps/data/filedata.txt 2> /apps/log/FileErrorlog.txt << EOF

Code:
set head off 
SET pagesize 0
SET LINESIZE 500
SET LONGCHUNKSIZE 500
SET LONG 320000000
SET RECSEP OFF
set SERVEROUTPUT off ECHO off
SET FEEDBACK OFF
whenever OSERROR EXIT 9
whenever SQLERROR EXIT sql.SQLCODE
SELECT FILEDATA FROM OCAU.FILEUPLOAD_OU WHERE FILESTATUS = 'T' AND FILETYPE = 'ACC' ORDER BY CREATEDATE ASC 
/
exit;
EOF 

I guess LONGCHUNKSIZE and LONG makes the trick? Please suggest solution for this
 

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Retrieve data from a file

Hello guys I want to retrieve two data from a file, like this: bash-2.03$ cat numtest 123456 123457 bash-2.03$ more ./test_num #!/bin/bash num1= num2= cnt=1 while read x do num${cnt}=$x cnt=$(($cnt+1)) done <$1 echo $num1 "\n" $num2 But when i executed this script, error... (2 Replies)
Discussion started by: tpltp
2 Replies

2. Programming

to find header in Mp3 file and retrieve data

hi all, In an mp3 file , data is arranged in sequence of header and data ,how to retrieve data between two headers. Is the data between two headers fixed? because as per theory it says 1152 samples will be there , but dont knw how many bits one sample correspond to? it would help if any c... (2 Replies)
Discussion started by: shashi
2 Replies

3. UNIX for Advanced & Expert Users

Retrieve data and redirect to a file

How to write a shell script to retrieve datas from database after that this database are redirect to a excell sheet and then i got a mail that gives details about the database with the column name and data.. I m using oracle 9i... Thanks, Anup Das (2 Replies)
Discussion started by: anupdas
2 Replies

4. Shell Programming and Scripting

How to retrieve data using awk command

I have a txt file with below data (textfile1.txt) select col1, col2 from Schema_Name.Table_Name1 select * from Schema_Name.Table_Name2 select col1, col2, col3 from Schema_Name.Table_Name3 select col1 from Schema_Name.Table_Name4 My output should look like Table_Name1 Table_Name2... (5 Replies)
Discussion started by: prasad4004
5 Replies

5. UNIX for Dummies Questions & Answers

How to compare two columns and retrieve data

I am a newbie to Unix and slowly learning it. I have a large data set with 8 different columns. I want to compare two columns and retrieve data if the two columns have similar number. I have attached the example. There are two columns (S-Contig and N-Contig). I want to retrieve the data from... (7 Replies)
Discussion started by: bjorngill
7 Replies

6. Shell Programming and Scripting

Help to retrieve data from two files matching a string

Hello Experts, I have come back to this forum after a while now, since require a better way to get my result.. My query is as below.. I have 3 files -- 1 Input file, 2 Data files .. Based on the input file, data has to be retreived matching from two files which has one common key.. For EX:... (4 Replies)
Discussion started by: shaliniyadav
4 Replies

7. UNIX for Dummies Questions & Answers

Retrieve data from Remote machine

Hello Please I ask if it is possible to recover data that is stored on a remote machine that I access via ssh on a usb ? if so, how? Thank you so much (5 Replies)
Discussion started by: chercheur857
5 Replies

8. Shell Programming and Scripting

Sed for select and retrieve data

I would like to recover the data from 3 text tags. These three markers are located between the tags specific location <tag1> and </tag1> knowing that they are in many places. In File.txt: <tag2>txt2</tag2> <tag3>txt3</tag3> <tag4>txt4</tag4> .... <tag1> <tag2>txt2</tag2>... (3 Replies)
Discussion started by: Amad
3 Replies

9. Shell Programming and Scripting

Compare columns of two files and retrieve data

Hi guys, I need your help. I have two files: file1 1 3 5 file2 1,XX 2,AA 3,BB 4,CC 5,DD I would like to compare the first column and where they are equal to write that output in a new file: 1,XX 3,BB (7 Replies)
Discussion started by: apenkov
7 Replies
icetImageCopyColor(3)						  IceT Reference					     icetImageCopyColor(3)

NAME
icetImageCopyColor,icetImageCopyDepth-- retrieve pixel data from image Synopsis #include <IceT.h> void icetImageCopyColorub( const IceTImage image, IceTUByte * color_buffer, IceTEnum color_format ); void icetImageCopyColorf( const IceTImage image, IceTFloat * color_buffer, IceTEnum color_format ); void icetImageCopyDepthf( const IceTImage image, IceTFloat * depth_buffer, IceTEnum depth_format ); Description The icetImageCopyColorsuite of functions retrieve color data from images and the icetImageCopyDepthfunctions retrieve depth data from images. Each function takes a pointer to an existing buffer that must be large enough to hold all pixels in the image. The data from the images is copied into these buffers, performing format conversions as necessary. Because data is copied into the provided buffer, subse- quently changing values in the buffer has no effect on the image object (as opposed to the behavior of icetImageGetColorand icetImageGet- Depth). The pixel data is always tightly packed in horizontal major order. Color data that comprises tuples such as RGBA have the components for each pixel packed together in that order. The first entry in the array corresponds to the pixel in the lower left corner of the image. The next entry is immediately to the right of the first pixel, and so on. The dimensions of the array can be retrieved with the icetIm- ageGetWidthand icetImageGetHeightfunctions. Each of these functions provides a typed version of the image data array. They can only succeed if the type the request matches the type specified by the color_format or depth_format argument. It is an error, for example, to request unsigned byte color data for a floating point color format. Although specifying the format may be redundant (it could be implied by the type being retrieved), IceT requires it for completeness and to support possible future data formats. Use icetImageCopyColorubto retrieve an array of 8-bit unsigned bytes. Using this function is only valid if color_format is ICET_IMAGE_COLOR_RGBA_UBYTE. Use icetImageCopyColorfto retrieve an array of floating point color values. Using this function is only valid if color_format is ICET_IMAGE_COLOR_RGBA_FLOAT. Use icetImageGetDepthfto retrieve an array of floating point depth values. Using this function is only valid if depth_format is ICET_IMAGE_DEPTH_FLOAT. Errors ICET_INVALID_OPERATION The image object does not have a color or depth buffer from which to copy data. ICET_INVALID_ENUM The requested color_format or depth_format is incompatible with the type of the buffer. Warnings None. Bugs None known. Copyright Copyright (C)2010 Sandia Corporation Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains certain rights in this software. This source code is released under the New BSD License. See Also icetImageGetColor(3), icetImageGetDepth(3) IceT Reference September 20, 2010 icetImageCopyColor(3)
All times are GMT -4. The time now is 10:11 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy