10-08-2007
hey Guys
I wanted to ask my question in detail what I wanted to achieve is
I have txt file
which looks like this
x.txt
5
8
10
15
17
19
I have abc.ksh and xyz.sql scripts
I want to read x.txt file into an array in abc.ksh (shell script) and pass that array to xyz.sql (sql script) where I wanted to read the values of that array and use those values in logic in xyz.sql (sql script).
Thanks
Apprciate any help
I am desperate and needed help
Pinky
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
I need to read the last file for a particular day, such as, "Jun 13" because the CSV file is cumulative for the entire day, so I don't want all the previous files, I just want the last file, for that day.
I ran an 'ls -al | grep "June 13" > myLs.txt' (simplified) to list all files from that day.... (2 Replies)
Discussion started by: yongho
2 Replies
2. Shell Programming and Scripting
How would I write a command(s) to read from a file (list) that looks like this: 29847374384 and grep from a second file (list) that looks like this: 29847374384, jkdfkjdf,3833,ddd:confused: (1 Reply)
Discussion started by: smellylizzard
1 Replies
3. UNIX for Dummies Questions & Answers
Hello,
I have a set of .txt files I cannot read.
This is a part of what I see.
Is there a way to view these files?
_MO<P.6D@K;WU<B$X-;)SIV/ROO!UL+1P=VTT-?,SLC`MI/6QMS#UYGGT\+)C=#\UIO`TL/0]=#/T)
it's about 3 pages.
Thanks for your help.
Joe (3 Replies)
Discussion started by: rcracerjoe
3 Replies
4. Shell Programming and Scripting
i'm a beginner in shell and i have a txt file that is updating every second or msec so i need a program to read the last line of this txt file
is this possible to do? (5 Replies)
Discussion started by: _-_shadow_-_
5 Replies
5. Shell Programming and Scripting
Hello All,
I just want help in coding a simple shell script since i am a newbie for UNIX and i started learning unix and shell scripting basics recently.
I am having a data like this in .txt file.
Product Name : XYZ
Price : 678.1
Best Buy Price : 600
Product Name : ABC
Price : 465... (3 Replies)
Discussion started by: vasanth_123
3 Replies
6. Shell Programming and Scripting
Hi All,
I have a .txt file with some contents as below:
Hi How are you?
# Fine and you?
I want a script file which reads the .txt file and output the lines which does not start with #.
Hi How are you?
Help is highly appreciated.
Please use code tags when posting data and... (5 Replies)
Discussion started by: bghosh
5 Replies
7. Shell Programming and Scripting
Hi Experts,
I am writing a shell script (for displaying disk space details) which is logging to 15 different servers using following command.
ssh userid@servername
It is prompting me for password for all 15 servers when I manually run it.
However , soon I would like to schedule this script... (4 Replies)
Discussion started by: ajaypatil_am
4 Replies
8. Shell Programming and Scripting
Hi Frnds...
I have an input file name.txt and another file named as source.. name.txt is having only one column and source is having around 25 columns...i need to read from name.txt line by line and search it in source file and then save the result in results file..
I have a rough idea about the... (15 Replies)
Discussion started by: ektubbe
15 Replies
9. Shell Programming and Scripting
Hi ...programmers...
I need a shell script to perform some specific task..
my txt file looks like this
netcdf new {
dimensions:
XAX1_11 = 11 ;
variables:
double XAX1_11(XAX1_11) ;
XAX1_11:point_spacing = "even" ;
XAX1_11:axis = "X" ;
float DEPTH(XAX1_11) ;... (19 Replies)
Discussion started by: Akshay Hegde
19 Replies
10. Shell Programming and Scripting
hi,
i'm trying to write a tcsh script that reads in a text file (one column) and the runs a different command for each line of text.
i've found lots of example commands for bash, but not for tcsh.
can anyone give me a hint?
thanks,
jill (8 Replies)
Discussion started by: giuinha
8 Replies
LEARN ABOUT DEBIAN
dspam_maintenance
dspam_maintenance(1) User Commands dspam_maintenance(1)
NAME
dspam_maintenance - remove old signatures and unimportant tokens from the DSPAM storage backend
SYNOPSIS
dspam_maintenance [--profile=PROFILE] [--logdays=no_of_days] [--signatures=no_of_days] [--neutral=no_of_days] [--unused=no_of_days]
[--hapaxes=no_of_days] [--hits1s=no_of_days] [--hits1i=no_of_days] [--without-sql-purge] [--with-sql-automatization] [--with-sql-autoup-
date] [--purgescriptdir=directory] [--with-all-drivers] [--verbose]
DESCRIPTION
dspam_maintenance is used to remove old signatures/tokens and unimportant tokens from the DSPAM storage backend and purge old log entries
in user and system logs.
This script can be called from the command line or run from within cron. Either add a line in your crontab or add this script in your
cron.{hourly,daily,weekly,monthly}. Running this script every hour might not be the best idea but it's your decision if you want to do so.
OPTIONS
--profile=PROFILE
Specify a storage profile from dspam.conf. The storage profile selected will be used for all database connectivity.
NOTE: See dspam.conf for more information.
--logdays=no_of_days
All log entries older than no_of_days days will be removed.
NOTE: Default is 31 days. (for more info: man dspam_logrotate)
--signatures=no_of_days
All signatures older than no_of_daysdays will be removed.
NOTE: Default value is set by the PurgeSignatures option in dspam.conf, if this option is not set, the default value is 14 days.
This option is only used for the Hash driver.
--neutral=no_of_days
Deletes all tokens from the target users database whose probability is between 0.35 and 0.65 (fairly neutral, useless data).
NOTE: Default value is set by the PurgeNeutral option in dspam.conf, if this option is not set, the default value is 90 days.
--unused=no_of_days
Remove stale tokens which have not been used for a long period of time.
NOTE: Default value is set by the PurgeUnused option in dspam.conf, if this option is not set, the default value is 90 days.
--hapaxes=no_of_days
Remove tokens with a total hit count below 5 (which will be assigned a hapaxial value by DSPAM).
NOTE: Default value is set by the PurgeHapaxes option in dspam.conf, if this option is not set, the default value is 30 days.
--hits1s=no_of_days
Remove tokens with a single SPAM hit.
NOTE: Default value is set by the PurgeHits1S option in dspam.conf, if this option is not set, the default value is 15 days.
--hits1i=no_of_days
Remove tokens with a single INNOCENT hit.
NOTE: Default value is set by the PurgeHits1I option in dspam.conf, if this option is not set, the default value is 15 days.
--without-sql-purge
Do not use SQL based purging. Only run dspam_clean.
NOTE: Default is off (aka: use SQL based purging).
--with-sql-optimization
Run VACUUM (for PostgreSQL/SQLite) and/or OPTIMIZE (for MySQL).
NOTE: Default is off (aka: do not use optimizations).
--with-sql-autoupdate
Run SQL based purging with purge day values passed to dspam_maintenance.
NOTE: Default is off (aka: do not attempt to modify SQL instructions).
--purgescriptdir=directory
Space separated list of directories where to search for SQL files used for the SQL based purging.
--with-all-drivers
Process all installed storage drivers (not just the active driver).
NOTE: Default is true (aka: process all installed drivers).
--verbose
Verbose output while running maintenance script.
EXIT VALUE
0 Operation was successful.
other Operation resulted in an error. Run the script with --verbose to get more information about error.
COPYRIGHT
Copyright (C) 2002-2010 DSPAM Project
All rights reserved.
For more information, see http://dspam.sourceforge.net.
SEE ALSO
dspam(1), dspam_admin(1), dspam_clean(1), dspam_crc(1), dspam_dump(1), dspam_logrotate(1), dspam_merge(1), dspam_stats(1), dspam_train(1)
dspam_maintenance Apr 26, 2010 dspam_maintenance(1)