The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
File properties risshanth UNIX for Dummies Questions & Answers 2 02-03-2008 12:57 AM
properties for vi shriashishpatil UNIX for Dummies Questions & Answers 2 04-20-2007 10:27 AM
Getting image properties victorin Shell Programming and Scripting 3 08-21-2006 01:53 PM
How do properties effect script? Chiefos UNIX for Dummies Questions & Answers 1 06-21-2006 03:23 AM
Directory properties trekker UNIX for Dummies Questions & Answers 8 11-20-2001 05:55 PM

Reply
 
Submit Tools LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 08-16-2007
Registered User
 

Join Date: Sep 2006
Location: Sg
Posts: 316
Stumble this Post!
Array Properties

Hi All,

I have a code below but i have problems trying to execute "cat $jpg[1]". Can anybody give me any advise? Is there something wrong with my syntax ?

Code:
#!/bin/csh

set qqq = 123
set www = 456

set jpg = ( $qqq $www )

cat $jpg[1]
Output:
Reply With Quote
Forum Sponsor
  #2 (permalink)  
Old 08-16-2007
Registered User
 

Join Date: Aug 2005
Posts: 38
Stumble this Post!
Try echo insteadof cat.
Reply With Quote
  #3 (permalink)  
Old 08-17-2007
Registered User
 

Join Date: Sep 2006
Location: Sg
Posts: 316
Stumble this Post!
Thanks it works!
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 01:26 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008 The CEP Blog All Rights Reserved -Ad Management by RedTyger Visit The Global Fact Book

Content Relevant URLs by vBSEO 3.2.0