cope exist file prioritie


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting cope exist file prioritie
# 1  
Old 02-24-2009
Question cope exist file prioritie

Hello

I want to make new file which have the same priorities of specified exist file, by super user,
and the file is no contents.

To explain it with example:

exist file:
ls -l old.sql
-rw-r--r-- 1 oracle oinstall 33 Feb 24 16:09 old.sql

if I copy and clean it.
cp -p old.sql new.sql && cat /dev/null > new.sql

ls -l new.sql
-rw-r--r-- 1 oracle oinstall 0 Feb 24 16:20 new.sql

but if the old.sql file is large the operation would be very bad in performance.

can it be finished by one command with good performance ?

thanks in advance.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

File not exist in direct

friends can do this from unix AIX I need to ask for a file that does not exist then if file.txt * **** echo "execute procedure" else *** echo "File does not exist" if You can sucedere that the file does not exist (2 Replies)
Discussion started by: tricampeon81
2 Replies

2. Shell Programming and Scripting

file exist in folder

Hi guys, I am new to shell script, i want to write shell script, the script details has mentioned below Two files are to be check in one particular directory, if the file exist in particular folder then the file is existed and also if the file exist more than three hours then send... (2 Replies)
Discussion started by: madhavi_bodi
2 Replies

3. Shell Programming and Scripting

Grepping file and returning passed variable if the value does not exist in file at all.

I have a list of fields that I want to check a file for, returning that field if it not found at all in the file. Is there a way to do a grep -lc and return the passed variable too rather then just the count? I am doing some crappy work-around now but I was not sure how to regrep this for :0 so... (3 Replies)
Discussion started by: personalt
3 Replies

4. Shell Programming and Scripting

Check if file exist

Hi, I created following script to check if file exist: #!/bin/bash SrcDir=$1 SrcFileName=$2 SrcTimePeriod=$3 if ;then echo 1 else echo 0 fi I ran it like: /apps/Scripts/FileExist.sh /apps/Inbox file1 2nd_period_2010 Even file exist at that location, my above command is... (4 Replies)
Discussion started by: palak08
4 Replies

5. Shell Programming and Scripting

Check if file exist

Hi, I am trying to create a bash script which will check if file exist then remove that file else do nothing. I have to do same process for three files in same script. I have written code for one file and trying to run it. if then rm -r /user1/abc/File1 fi When I run this code it... (1 Reply)
Discussion started by: palak08
1 Replies

6. Shell Programming and Scripting

How to Check whether list file present in TXT file exist or not

Hi All, I have txt file which has list of files. I have to check whether these files exist or not. Thanks supriya (6 Replies)
Discussion started by: supriyabv
6 Replies

7. Shell Programming and Scripting

File exist test

Can someone please shed light on why this may not be working, file does exist, but I get an error if ] then echo "No ${source_path}/${file_mask} found - ">> ${logfile} result=1 check_result ${result} "Failed to find file... (4 Replies)
Discussion started by: Pokermad
4 Replies

8. Shell Programming and Scripting

trying to cope with awk difficulties

The data we are searching is populated in this way: ----IP---------DAY----MONTH----DATE--------TIME---------YEAR 12.3234.34-----Fri------Nov-------15-------18:05:14 GMT---2008 I want the user to be able to search for the data according to month and year. However, I cannot quite figure out... (8 Replies)
Discussion started by: amatuer_lee_3
8 Replies

9. Shell Programming and Scripting

Have a shell script check for a file to exist before processing another file

I have a shell script that runs all the time looking for a certain type of file and then it processes the file through a series of other scripts. The script is watching a directory that has files uploaded to it via SFTP. It already checks the size of the file to make sure that it is not still... (3 Replies)
Discussion started by: heprox
3 Replies

10. UNIX for Dummies Questions & Answers

how to check if the file exist or not?

say i would like to check if the file is existed before i use rm command. How can i do it? i know if i can use find, but i would like to have a good interface (in a shell script) thks (3 Replies)
Discussion started by: gusla
3 Replies
Login or Register to Ask a Question
GLPRIORITIZETEXTURES(3G)												  GLPRIORITIZETEXTURES(3G)

NAME
glPrioritizeTextures - set texture residence priority C SPECIFICATION
void glPrioritizeTextures( GLsizei n, const GLuint *textures, const GLclampf *priorities ) PARAMETERS
n Specifies the number of textures to be prioritized. textures Specifies an array containing the names of the textures to be prioritized. priorities Specifies an array containing the texture priorities. A priority given in an element of priorities applies to the texture named by the corresponding element of textures. DESCRIPTION
glPrioritizeTextures assigns the n texture priorities given in priorities to the n textures named in textures. The GL establishes a ``working set'' of textures that are resident in texture memory. These textures may be bound to a texture target much more efficiently than textures that are not resident. By specifying a priority for each texture, glPrioritizeTextures allows applications to guide the GL implementation in determining which textures should be resident. The priorities given in priorities are clamped to the range [0,1] before they are assigned. 0 indicates the lowest priority; textures with priority 0 are least likely to be resident. 1 indicates the highest priority; textures with priority 1 are most likely to be resident. However, textures are not guaranteed to be resident until they are used. glPrioritizeTextures silently ignores attempts to prioritize texture 0, or any texture name that does not correspond to an existing tex- ture. glPrioritizeTextures does not require that any of the textures named by textures be bound to a texture target. glTexParameter may also be used to set a texture's priority, but only if the texture is currently bound. This is the only way to set the priority of a default tex- ture. NOTES
glPrioritizeTextures is available only if the GL version is 1.1 or greater. ERRORS
GL_INVALID_VALUE is generated if n is negative. GL_INVALID_OPERATION is generated if glPrioritizeTextures is executed between the execution of glBegin and the corresponding execution of glEnd. ASSOCIATED GETS
glGetTexParameter with parameter name GL_TEXTURE_PRIORITY retrieves the priority of a currently bound texture. SEE ALSO
glAreTexturesResident, glBindTexture, glCopyTexImage1D, glCopyTexImage2D, glTexImage1D, glTexImage2D, glTexImage3D, glTexParameter GLPRIORITIZETEXTURES(3G)