Sponsored Content
Full Discussion: Escaping a variable in ksh
Top Forums UNIX for Beginners Questions & Answers Escaping a variable in ksh Post 303032594 by jeffs42885 on Wednesday 20th of March 2019 05:14:32 PM
Old 03-20-2019
Your first approximation worked!

Thank you!
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

ksh: A part of variable A's name is inside of variable B, how to update A?

This is what I tried: vara=${varb}_count (( vara += 1 )) Thanks for help (4 Replies)
Discussion started by: pa3be
4 Replies

2. Shell Programming and Scripting

ksh - get stdout name as variable

Writing a ksh script. If someone starts a process with: test.ksh > date.log How can I grab 'date.log' name as a variable in test.ksh? I need to get the 'date.log' name (not the contents) as a variable...without entering something like 'test.ksh date.log > date.log' (4 Replies)
Discussion started by: mhcueball2
4 Replies

3. Shell Programming and Scripting

KSH variable substitution

Hi folks Please let me know if anyone knows how to handle this. My KSH script -> testscript.ksh cmd=$1 ENV="devl" echo $cmd This is how I call the script ./testscript.ksh 'ps -ef | grep br$ENV' How do I get this to print the below text i.e $ENV should be substituted with the value... (5 Replies)
Discussion started by: tipsy
5 Replies

4. Shell Programming and Scripting

problem escaping newline in ksh

Hi, I did the below. $ print "\\n" $ I am curious, why does \\n give two new lines? I would have thought that the first \ would escape the second \, and so we'd get \n printed. But we didn't. Any ideas? Thanks. (7 Replies)
Discussion started by: JamesByars
7 Replies

5. Shell Programming and Scripting

Escaping the * character in ksh.

Hi All, In ksh script i'm trying to assign "sqlstmt1" varaible value, update VAREntryTb set VAR10num = VAR1num * Mltplr where BusD = '$val1' and RunI = 1"` Hence i wrote below statement, the issue with this is shell is expanding "*" character adn thus subistuting it with the content of my... (6 Replies)
Discussion started by: arvindcgi
6 Replies

6. Shell Programming and Scripting

checking variable has value - ksh

hi all, i have a shell (ksh) script where i am reading line by line from a grep command and i wanted to check if the grep command actually returned something or was null. i can do this by using -z : if ; then ..... but this forces me to do something when $myVariable is null when i... (3 Replies)
Discussion started by: cesarNZ
3 Replies

7. UNIX for Dummies Questions & Answers

Question on using a variable in KSH

Hi all, The below command tries to copy ".tgz" instead of "hello_test.tgz" -- It seems as if the underscore gets in the way. I tried with different ways of using quotes, with no luck, unfortunately...it's probably very simple, but may I ask how this would be done: How would the below be... (3 Replies)
Discussion started by: chatguy
3 Replies

8. Shell Programming and Scripting

setting variable value to dynamic sed match - escaping hell

Hello All, I'm trying to write a script that will perform a dynamic match (of a dynamic variable) and set a variable to have the resulting (match) value. The idea is that the environment variable to check ($1) and the regular expression to use ($2) are given as parameters. For example,... (5 Replies)
Discussion started by: aedgar
5 Replies

9. Shell Programming and Scripting

Variable to command to Variable Question KSH

Hello, First post for Newbie as I am stumped. I need to get certain elements for a specific PID from the ps command. I am attempting to pass the value for the PID I want to retrieve the information for as a variable. When the following is run without using a variable, setting a specific PID,... (3 Replies)
Discussion started by: Coyote270WSM
3 Replies

10. Shell Programming and Scripting

sed - replacement file path with variable - Escaping / character

Hi,, I have the line below in a file: $!VarSet |LFDSFN1| = '"E:\APC\Trials\20140705_427_Prototype Trial\Data\T4_20140705_Trial_Cycle_Data_13_T_Norm.txt" "VERSION=100 FILEEXT=\"*.txt\" FILEDESC=\"General Text\" "+""+"TITLE{SEARCH=NONE NAME=\"New Dataset\" LINE=1I want to write a script to change... (2 Replies)
Discussion started by: carlr
2 Replies
QMetaProperty(3qt)														QMetaProperty(3qt)

NAME
QMetaProperty - Stores meta data about a property SYNOPSIS
#include <qmetaobject.h> Public Members const char * type () const const char * name () const bool writable () const bool isSetType () const bool isEnumType () const QStrList enumKeys () const int keyToValue ( const char * key ) const const char * valueToKey ( int value ) const int keysToValue ( const QStrList & keys ) const QStrList valueToKeys ( int value ) const bool designable ( QObject * o = 0 ) const bool scriptable ( QObject * o = 0 ) const bool stored ( QObject * o = 0 ) const bool reset ( QObject * o ) const DESCRIPTION
The QMetaProperty class stores meta data about a property. Property meta data includes type(), name(), and whether a property is writable(), designable() and stored(). The functions isSetType(), isEnumType() and enumKeys() provide further information about a property's type. The conversion functions keyToValue(), valueToKey(), keysToValue() and valueToKeys() allow conversion between the integer representation of an enumeration or set value and its literal representation. Actual property values are set and received through QObject's set and get functions. See QObject::setProperty() and QObject::property() for details. You receive meta property data through an object's meta object. See QMetaObject::property() and QMetaObject::propertyNames() for details. See also Object Model. MEMBER FUNCTION DOCUMENTATION
bool QMetaProperty::designable ( QObject * o = 0 ) const Returns TRUE if the property is designable for object o; otherwise returns FALSE. If no object o is given, the function returns a static approximation. QStrList QMetaProperty::enumKeys () const Returns the possible enumeration keys if this property is an enumeration type (or a set type). See also isEnumType(). bool QMetaProperty::isEnumType () const Returns TRUE if the property's type is an enumeration value; otherwise returns FALSE. See also isSetType() and enumKeys(). bool QMetaProperty::isSetType () const Returns TRUE if the property's type is an enumeration value that is used as set, i.e. if the enumeration values can be OR-ed together; otherwise returns FALSE. A set type is implicitly also an enum type. See also isEnumType() and enumKeys(). int QMetaProperty::keyToValue ( const char * key ) const Converts the enumeration key key to its integer value. For set types, use keysToValue(). See also valueToKey(), isSetType(), and keysToValue(). int QMetaProperty::keysToValue ( const QStrList & keys ) const Converts the list of keys keys to their combined (OR-ed) integer value. See also isSetType() and valueToKey(). const char * QMetaProperty::name () const Returns the name of the property. bool QMetaProperty::reset ( QObject * o ) const Tries to reset the property for object o with a reset method. On success, returns TRUE; otherwise returns FALSE. Reset methods are optional, usually only a few properties support them. bool QMetaProperty::scriptable ( QObject * o = 0 ) const Returns TRUE if the property is scriptable for object o; otherwise returns FALSE. If no object o is given, the function returns a static approximation. bool QMetaProperty::stored ( QObject * o = 0 ) const Returns TRUE if the property shall be stored for object o; otherwise returns FALSE. If no object o is given, the function returns a static approximation. const char * QMetaProperty::type () const Returns the type of the property. const char * QMetaProperty::valueToKey ( int value ) const Converts the enumeration value value to its literal key. For set types, use valueToKeys(). See also isSetType() and valueToKeys(). QStrList QMetaProperty::valueToKeys ( int value ) const Converts the set value value to a list of keys. See also isSetType() and valueToKey(). bool QMetaProperty::writable () const Returns TRUE if the property is writable; otherwise returns FALSE. SEE ALSO
http://doc.trolltech.com/qmetaproperty.html http://www.trolltech.com/faq/tech.html COPYRIGHT
Copyright 1992-2001 Trolltech AS, http://www.trolltech.com. See the license file included in the distribution for a complete license statement. AUTHOR
Generated automatically from the source code. BUGS
If you find a bug in Qt, please report it as described in http://doc.trolltech.com/bughowto.html. Good bug reports help us to help you. Thank you. The definitive Qt documentation is provided in HTML format; it is located at $QTDIR/doc/html and can be read using Qt Assistant or with a web browser. This man page is provided as a convenience for those users who prefer man pages, although this format is not officially supported by Trolltech. If you find errors in this manual page, please report them to qt-bugs@trolltech.com. Please include the name of the manual page (qmetaproperty.3qt) and the Qt version (3.1.1). Trolltech AS 9 December 2002 QMetaProperty(3qt)
All times are GMT -4. The time now is 04:10 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy