Sponsored Content
Top Forums Shell Programming and Scripting /usr/local/bin/expr function not working Post 302607677 by itkamaraj on Thursday 15th of March 2012 05:23:21 AM
Old 03-15-2012
what is there in /tmp/loadDSdata.tmpl ?

---------- Post updated at 02:53 PM ---------- Previous update was at 02:48 PM ----------

if the BASENAME is numeric then you can try the below

Code:
 
len=$((${#BASENAME}+2))
len=$((${#len}+7))

 

10 More Discussions You Might Find Interesting

1. Solaris

/usr/bin/cut not working with largefiles on Solaris 10

I have a person running a perl script that is parsing > 2G log files and pipes to cut -d " " -f 1,6,7,8... The script itself is in a nfs mounted home directory. It runs fine when started from a solaris 8 box but fails after about 400 lines when started from the solaris 10 box. The solaris... (1 Reply)
Discussion started by: wottie
1 Replies

2. Shell Programming and Scripting

#/usr/bin/csh -f not working as expected?

Hey everyone, A coworker of mine has written a csh script that starts with #!/usr/bin/csh -f. It's my understanding that the -f should skip the .cshrc and .login files, but here's the problem: In the script "line" is used, and I happen to have a "line" in my ~/bin. When the script is ran my... (4 Replies)
Discussion started by: effigy
4 Replies

3. Solaris

Questions about /usr/local/bin & scripts.

Hi gentlemen. For what intended is the directory /usr/local/bin? In this directory are some script. I don't understand how these scripts being in this directory are started. Each time after registration of the user occurs start of these scripts. These scripts start applications. (7 Replies)
Discussion started by: wolfgang
7 Replies

4. OS X (Apple)

When to use /Users/m/bin instead of /usr/local/bin (& whats the diff?)?

Q1. I understand that /usr/local/bin means I can install/uninstall stuff in here and have any chance of messing up my original system files or effecting any other users. I created this directory myself. But what about the directory I didn't create, namely /Users/m/bin? How is that directory... (1 Reply)
Discussion started by: michellepace
1 Replies

5. AIX

/usr/local/bin/cvs: Not found

I can able to access /usr/local/bin/cvs in the terminal (AIX 6.1 Box). but i am getting the "/usr/local/bin/cvs: Not found " when i call it from the script. please some one assist me what maybe problem (6 Replies)
Discussion started by: hifirockz
6 Replies

6. Shell Programming and Scripting

/usr/bin/time Shell Scripting Function

Hello, I have made a Linux Shell Script that downloads 6 files from the Internet and then deletes them. Now i want to use the function "/usr/bin/time" and "bc" to calculate how long the avergate run time for the shell script is. I therefore need to do it 100 times. My shell script code is below: ... (6 Replies)
Discussion started by: solo2
6 Replies

7. Shell Programming and Scripting

Possible to use /usr/bin/watch to call a function?

I want to have a script both define functions and have the ability to run an external program calling one of them. This is the simplified construct: #!/bin/bash foo() { echo "this is foo" } bar() { echo "this is bar" } case "$1" in one) foo ;; two) export... (1 Reply)
Discussion started by: graysky
1 Replies

8. Solaris

How to link sed from /usr/bin/sed to /usr/local/bin/sed?

Hi Guys, OS:- Solaris 10 64Bit I have a small query. On one server a user is facing sed command issue. He gets error regarding sed for this location /users/hoy/2999/batch5/bin/internal.sh: /usr/local/bin/sed: not found How ever the sed is actually present at this location on server:-... (13 Replies)
Discussion started by: manalisharmabe
13 Replies

9. Shell Programming and Scripting

Nested if not working with /usr/xpg4/bin/awk

Hi, I am trying to do if inside the If in /usr/xpg4/bin/awk. But I am getting below error : /usr/xpg4/bin/awk -v a="${THREADIDARR }" 'BEGIN {FS="|"; n=split(a,b," "); for(i=1; i<=n; i++) c]=1;} length($3) == 0{ftag == 1{{print}}; length($3) != 0{$3 in c{ftag=1;print;} !$3 in c{ftag=0;}}'... (4 Replies)
Discussion started by: nes
4 Replies

10. BSD

FreeBSD: /usr/bin/ld not looking in /usr/local/lib

I'm not sure if this is the default behavior for the ld command, but it does not seem to be looking in /usr/local/lib for shared libraries. I was trying to compile the latest version of Kanatest from svn. The autorgen.sh script seems to exit without too much trouble: $ ./autogen.sh checking... (2 Replies)
Discussion started by: AntumDeluge
2 Replies
qpdldecode(1)						      General Commands Manual						     qpdldecode(1)

NAME
qpdldecode - Decode a QPDL stream into human readable form. SYNOPSIS
qpdldecode [options] <qpdl-file DESCRIPTION
qpdldecode decodes a QPDL stream into human readable form. Only the JBIG compression format(0x13) is handled. An QPDL stream is the printer langauge used by the Samsung CLP-300, CLP-600, CLX-3160 and the Xerox Phaser 6110 printers. COMMAND LINE OPTIONS
These are the options that can appear on the command line. -d basename Basename of .pbm file for saving decompressed planes. -h Print hex file offsets. -o Print file offsets. -D level Set Debug level [0]. EXAMPLES
Decode an QPDL stream file created by foo2qpdl. 0: 33%-12345X@PJL DEFAULT SERVICEDATE=20070212 2c: @PJL SET USERNAME="Unknown" 49: @PJL SET JOBNAME="testpage.pdf" 6a: @PJL SET COLORMODE=COLOR 84: @PJL SET PAPERTYPE = NORMAL a1: @PJL ENTER LANGUAGE = QPDL bd: RECTYPE 0x0 len=17 res=600, copies=1, papersize=letter(0), w=2550, h=3300 papersource=auto, unk=0, duplex=0:0, unk=0,2, unk=268(0x10c) ce: RECTYPE 0xc len=68(0x44) stripe=0, WB=1248(0x4e0), H=128(0x80), plane=4, comp=0x13, len=56(0x38) magic=0x39abcdef, len=20(0x14), unk=0,0,0,0,0,0, checksum=0x356 DL = 0, D = 0, P = 1, - = 0, XY = 9984 x 6400 L0 = 6400, MX = 0, MY = 0 Order = 0 Options = 72 LRLTWO TPBON 1 stripes, 0 layers, 1 planes 112: RECTYPE 0xc len=68(0x44) stripe=0, WB=1248(0x4e0), H=128(0x80), plane=1, comp=0x13, len=56(0x38) magic=0x39abcdef, len=20(0x14), unk=0,0,0,0,0,0, checksum=0x356 DL = 0, D = 0, P = 1, - = 0, XY = 9984 x 6400 L0 = 6400, MX = 0, MY = 0 Order = 0 Options = 72 LRLTWO TPBON 1 stripes, 0 layers, 1 planes 156: RECTYPE 0xc len=68(0x44) stripe=0, WB=1248(0x4e0), H=128(0x80), plane=2, comp=0x13, len=56(0x38) magic=0x39abcdef, len=20(0x14), unk=0,0,0,0,0,0, checksum=0x356 DL = 0, D = 0, P = 1, - = 0, XY = 9984 x 6400 L0 = 6400, MX = 0, MY = 0 Order = 0 Options = 72 LRLTWO TPBON 1 stripes, 0 layers, 1 planes 19a: RECTYPE 0xc len=68(0x44) stripe=0, WB=1248(0x4e0), H=128(0x80), plane=3, comp=0x13, len=56(0x38) magic=0x39abcdef, len=20(0x14), unk=0,0,0,0,0,0, checksum=0x356 DL = 0, D = 0, P = 1, - = 0, XY = 9984 x 6400 L0 = 6400, MX = 0, MY = 0 Order = 0 Options = 72 LRLTWO TPBON 1 stripes, 0 layers, 1 planes 1de: RECTYPE 0xc len=77488(0x12eb0) stripe=1, WB=1248(0x4e0), H=128(0x80), plane=1, comp=0x13, len=77476(0x12ea4) magic=0x39abcdef, len=77440(0x12e80), unk=2000000,0,0,0,0,0, checksum=0x9326d7 1308e: RECTYPE 0xc len=77680(0x12f70) stripe=1, WB=1248(0x4e0), H=128(0x80), plane=2, comp=0x13, len=77668(0x12f64) magic=0x39abcdef, len=77632(0x12f40), unk=2000000,0,0,0,0,0, checksum=0x9367e5 25ffe: RECTYPE 0xc len=69232(0x10e70) stripe=1, WB=1248(0x4e0), H=128(0x80), plane=3, comp=0x13, len=69220(0x10e64) magic=0x39abcdef, len=69184(0x10e40), unk=2000000,0,0,0,0,0, checksum=0x83938a 36e6e: RECTYPE 0xc len=45616(0xb230) stripe=1, WB=1248(0x4e0), H=128(0x80), plane=4, comp=0x13, len=45604(0xb224) magic=0x39abcdef, len=45568(0xb200), unk=2000000,0,0,0,0,0, checksum=0x58015d 4209e: RECTYPE 0x1 len=3 copies=1 420a1: RECTYPE 0x9 len=0 420a2: 33%-12345X FILES
/usr/bin/qpdldecode SEE ALSO
foo2qpdl-wrapper(1), foo2qpdl(1) AUTHOR
Rick Richardson <rick.richardson@comcast.net> http://foo2qpdl.rkkda.com/
All times are GMT -4. The time now is 06:52 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy