03-26-2013
Howto compare the columns of 2 diff tables of 2 different schemas in UNIX shell script
HI All,
I am new to Unix shell scripts..
Could you please post the unix shell script for for the below request.,
There are two different tables(sample1, sample2) in different schemas(s_schema1, s_schema2).
Unix shell script to compare the columns of two different tables of two different schemas and provide whether the data in the tables are similar or not and count of the column with the status in the row( for eg: some rows have the status with "LOADED" and some with "ERROR")
The column in tables(sample1, sample2) are having the different data type.
Thanks in advance.
Regards,
Rajkumar Gopal
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I am trying to transpose tables listed in the format into format. Any help would be greatly appreciated.
Input:
test_data_1
1 2 90%
4 3 91%
5 4 90%
6 5 90%
9 6 90%
test_data_2
3 5 92%
5 4 92%
7 3 93%
9 2 92%
1 1 92%
...
Output:... (7 Replies)
Discussion started by: justthisguy
7 Replies
2. Shell Programming and Scripting
Hi,
I want to compare two tables fieldwise using shell script. Can anyone help me regarding the same.
The approach which i tried is to first move the two tables in simple txt file where each field is now seperated by space. But i can't retrive each field with "space" as a seperator b'coz there... (1 Reply)
Discussion started by: dtidke
1 Replies
3. Shell Programming and Scripting
Hi,
i am new to perl scripting.. i am still learing it.. i am asked to write a perl script which should compare 2 coloums of 2 different files. if those 2 coloumn are same the script should store the both the lines in 2 diff files.
these are files,
file 1:
21767016 226112 char
19136520... (3 Replies)
Discussion started by: vasuki
3 Replies
4. Shell Programming and Scripting
i have a file which if you will open as xls will yield something like this:
Column1 Column2 Column3
ABC CDE EFG
GHI IJK KLM
MNO OPQ QRS
what i want to need is to have this kind of results:
Column1
ABC CDE EFG
GHI IJK ... (10 Replies)
Discussion started by: kingpeejay
10 Replies
5. Red Hat
Hi,
I have two server , one linux and one unix .
I want to compare two different directry in them .
What command or tool I can use instead of search the dir one by one ???
thank (3 Replies)
Discussion started by: chuikingman
3 Replies
6. Shell Programming and Scripting
Hi Friends Need your expertise.
Command to check the difference and compare 2 files and remove lines . example
File1 is master copy and File2 is a slave copy . whenever i change, add or delete a record in File1 it should update the same in slave copy . Can you guide me how can i accomplish... (3 Replies)
Discussion started by: ajayram_arya
3 Replies
7. Shell Programming and Scripting
Hi All,
In my script I have used the below code to retrieve the instance name
V_INSTANCE_NAME=`sqlplus -s ${APPS_USR_PSWD} <<+
set pagesize 0 linesize 256 feedback off verify off head off echo off
set serveroutput off
select... (2 Replies)
Discussion started by: kalidoss
2 Replies
8. UNIX for Dummies Questions & Answers
#!/bin/sh
b= SERVER
if ;
then
echo "hostname $a is same"
____________________________ (17 Replies)
Discussion started by: Nsharma3006
17 Replies
9. HP-UX
Heyy,
any help would be grateful....
LOOKING FOR THE WAYS TO SEND AN EMAIL WITH ATTACHMENT & HTML TABLES IN BODY THROUGH SHELL SCRIPT (LINUX)..NOT SURE, IF WE HAVE ANY INBUILT HTML TAG OR UNIX COMMAND TO SEND THE ATTACHMENTS. KINDLY HELP
below is small script posted for our understanding..... (2 Replies)
Discussion started by: Harsha Vardhan
2 Replies
10. UNIX for Beginners Questions & Answers
Hello All,
I am new to unix scripting. I need to read FROMINSTANCE, FROMFIELD from below XML code and need to write a script for
insert into SQ_EPIC values( "DID", "PROJECT_NAME")
Select DID, PROJECT_NAME from EPIC<CONNECTOR TOINSTANCETYPE="Source Qualifier" TOINSTANCE="SQ_EPIC" TOFIELD="DID"... (7 Replies)
Discussion started by: sekhar.lsb
7 Replies
LEARN ABOUT LINUX
npm-run-script
NPM-RUN-SCRIPT(1) NPM-RUN-SCRIPT(1)
NAME
npm-run-script - Run arbitrary package scripts
SYNOPSIS
npm run-script <command> [--silent] [-- <args>...]
alias: npm run
DESCRIPTION
This runs an arbitrary command from a package's "scripts" object. If no "command" is provided, it will list the available scripts.
run[-script] is used by the test, start, restart, and stop commands, but can be called directly, as well. When the scripts in the package
are printed out, they're separated into lifecycle (test, start, restart) and directly-run scripts.
As of ` https://blog.npmjs.org/post/98131109725/npm-2-0-0, you can use custom arguments when executing scripts. The special option -- is
used by getopt https://goo.gl/KxMmtG to delimit the end of the options. npm will pass all the arguments after the -- directly to your
script:
npm run test -- --grep="pattern"
The arguments will only be passed to the script specified after npm run and not to any pre or post script.
The env script is a special built-in command that can be used to list environment variables that will be available to the script at run-
time. If an "env" command is defined in your package, it will take precedence over the built-in.
In addition to the shell's pre-existing PATH, npm run adds node_modules/.bin to the PATH provided to scripts. Any binaries provided by
locally-installed dependencies can be used without the node_modules/.bin prefix. For example, if there is a devDependency on tap in your
package, you should write:
"scripts": {"test": "tap test/*.js"}
instead of
"scripts": {"test": "node_modules/.bin/tap test/*.js"}
to run your tests.
The actual shell your script is run within is platform dependent. By default, on Unix-like systems it is the /bin/sh command, on Windows it
is the cmd.exe. The actual shell referred to by /bin/sh also depends on the system. As of `
https://github.com/npm/npm/releases/tag/v5.1.0 you can customize the shell with the script-shell configuration.
Scripts are run from the root of the module, regardless of what your current working directory is when you call npm run. If you want your
script to use different behavior based on what subdirectory you're in, you can use the INIT_CWD environment variable, which holds the full
path you were in when you ran npm run.
npm run sets the NODE environment variable to the node executable with which npm is executed. Also, if the --scripts-prepend-node-path is
passed, the directory within which node resides is added to the PATH. If --scripts-prepend-node-path=auto is passed (which has been the
default in npm v3), this is only performed when that node executable is not found in the PATH.
If you try to run a script without having a node_modules directory and it fails, you will be given a warning to run npm install, just in
case you've forgotten.
You can use the --silent flag to prevent showing npm ERR! output on error.
You can use the --if-present flag to avoid exiting with a non-zero exit code when the script is undefined. This lets you run potentially
undefined scripts without breaking the execution chain.
SEE ALSO
o npm help 7 scripts
o npm help test
o npm help start
o npm help restart
o npm help stop
o npm help 7 config
January 2019 NPM-RUN-SCRIPT(1)