Export command in unix


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Export command in unix
# 1  
Old 01-17-2011
Export command in unix

Hi,

executing below command for export in cygwin, though I have already mentioned the username and password with the command but on execution it again asks for username, what modification is needed in the below command ? may be there is some problem in using inverted comma ?

Code:
exp `sys/password@dblocal as sysdba`  file=c:/testexp.dmp log=c:/testexp.log owner=testabc

Regards

Last edited by Scott; 01-17-2011 at 07:02 AM.. Reason: Please use code tags
# 2  
Old 01-17-2011
Yes, there is a problem using the back-quote, aka `. The contents of the string enclosed in the back-quotes are invoked as a command, and the command's output replaces the back-quoted string. For example:
Code:
file `which ls`

is expanded into:
Code:
file /bin/ls

You need to use single-quotes: '

Look at the bash or ksh manual pages for more information about quoting and command line expansion.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

export in unix

hi i have some lines in a text file like, export ORACLE_HOME=/home/dell/instantclient_11_2 export LD_LIBRARY_PATH=$ORACLE_HOME:${LD_LIBRARY_PATH} export PATH=$ORACLE_HOME:$ORACLE_HOME/sdk:${PATH} how to run this file such that every line will be exported in unix session (3 Replies)
Discussion started by: mprakasheee
3 Replies

2. Shell Programming and Scripting

When i am trying to execute export command within a shell script it is saying command not found.

I am running the export command within a view to use that value inside my build script. But while executing it it is saying "export command not found" My code is as follows: -------------------------- #!/bin/sh user="test" DIR="/bldtmp/"$user VIEW="test.view1" echo "TMPDIR before export... (4 Replies)
Discussion started by: dchoudhury
4 Replies

3. UNIX for Dummies Questions & Answers

How to export a command ?

Hi The command "ssh -V" works as normal user but fails as root. As Normal user: bash-3.00$ ssh -V OpenSSH_5.9p1, OpenSSL 1.0.0e 6 Sep 2011As Root user: # ssh -V bash: ssh: command not found Thanks (1 Reply)
Discussion started by: frintocf
1 Replies

4. Shell Programming and Scripting

Need help for export command

Hi, I need help for using export command. Lets consider there are 2 servers ie. A & B. I am running one script on server A which calls another script on server B using remsh command. There is one variable in the script on server B which do not gets evaluated and ultimately i get the error. ... (3 Replies)
Discussion started by: tushar_shah06
3 Replies

5. Shell Programming and Scripting

Export Command

Hello All, I am transferring a file from one server to another server. File name is stored as Wip_DD-MM-YY .i.e if we run the program today the file is stored as Wip_18-FEB-09.txt. This file i need to transfer. My question is how do we assign the this filename to a variable. i treid in... (3 Replies)
Discussion started by: chpraveen_862
3 Replies

6. Shell Programming and Scripting

awk/sed Command : Parse parameter file / send the lines to the ksh export command

Sorry for the duplicate thread this one is similar to the one in https://www.unix.com/shell-programming-scripting/88132-awk-sed-script-read-values-parameter-files.html#post302255121 Since there were no responses on the parent thread since it got resolved partially i thought to open the new... (4 Replies)
Discussion started by: rajan_san
4 Replies

7. UNIX for Advanced & Expert Users

Export command

Hi all, Want to know what does export command do?? What is its functionality? And on a shell prompt $at=1 $ echo $at 1 The variable above is it available to other script??? (3 Replies)
Discussion started by: prakash.kudreka
3 Replies

8. UNIX for Advanced & Expert Users

UNIX export command - memory space

Hello, I have 2 or more environment files, with identical variable names; see below: .env_file1 export PROJNAME="XYZ" export PROJID="2" .env_file2 export PROJNAME="WSX" export PROJID="9" .env_file(n) export PROJNAME="QAZ" export PROJID="12" The env files above will be sourced... (2 Replies)
Discussion started by: Nomaad
2 Replies

9. UNIX for Dummies Questions & Answers

export command

Is there any difference between these 2 commands :- export var="a" and var="a" export var (2 Replies)
Discussion started by: radhika03
2 Replies

10. Shell Programming and Scripting

using export command

I saw a unix shell script in which export command is used like this : export filename what is a file exported for ? thanks srini (4 Replies)
Discussion started by: sveera
4 Replies
Login or Register to Ask a Question