Sponsored Content
Top Forums Shell Programming and Scripting Need help with a sh script to spool directory and modify the output (Oracle cnt file) Post 302328520 by vgersh99 on Wednesday 24th of June 2009 12:56:28 PM
Old 06-24-2009
YMMV:
Code:
sed -e '/log0.*/d' -e 's#prod_c#test#' -e "s#.*#'&',#" -e '$s#,$##'

 

9 More Discussions You Might Find Interesting

1. Solaris

removing particular lines ending with a .cnt extension in a text file

I have a text file with rows of information (it is basically a ls command information(o/p from ls command)) I need to remove the lines ending with a .cnt extension and keep the lines ending with .zip extension, how to accomplish this. I also only need the date,size and name of the file from every... (2 Replies)
Discussion started by: ramky79
2 Replies

2. Shell Programming and Scripting

To spool output from a database query

Hi all, I would want to spool file for a database query, however by using crontab, the file is not spooled. Below shows my script: ORACLE_HOME="/u01/oraprod/perpdb/10.1.0/db_1" OUTFILE="/tmp/invalid.out" FILE="$HOME/admin/scripts" $ORACLE_HOME/bin/sqlplus -s "/as sysdba"... (0 Replies)
Discussion started by: *Jess*
0 Replies

3. Shell Programming and Scripting

Help in Shell scripting to modify the User Creation script in oracle database.

Hi, I have several users to create on my test Oracle database taking the scripts from the Production Oracle database. I have a separate text file where I have user-id and passwords maintained. I need help in writing a shell script to go thru the user creation scripts and replace VALUES... (1 Reply)
Discussion started by: rparavastu
1 Replies

4. Solaris

Spool directory

hi all, I have unix box I install 2 zone on it I want to make spool directory and assign one to each zone How can I do that ? (5 Replies)
Discussion started by: coxmanchester
5 Replies

5. Shell Programming and Scripting

Help supressing spool output from screen when calling sqlplus from script

I'm calling an embedded sql from my shell script file. This sql does simple task of spooling out the contents of the table (see below my sample code) into a spool file that I specify. So far so good, but the problem is that the output is also displayed on screen which I do NOT want. How can I... (3 Replies)
Discussion started by: MxC
3 Replies

6. Shell Programming and Scripting

SQL*PLUS Spool Output

Hi, Im writing a script to run a bit of sql(via sqlplus) that pulls back some data and spools it to a file, I want the spool file to only display the data, with no sql command at the top and no reports at the bottom ie(# of records recieved). I am currently doing it via a grep command but... (1 Reply)
Discussion started by: Magezy
1 Replies

7. Shell Programming and Scripting

Need a script for automatically cleaning up /var/spool/cups directory

Hi Friends, Actually in an linux server , there was printer jobs files occupying more space in /var/spool/cups so i want a script for deleting the files once in two week since i need the latest two weeks files. Thanks in advance..Waiting for the script. (2 Replies)
Discussion started by: Mohamed Thamim
2 Replies

8. UNIX and Linux Applications

UNIX spool command not extracting complete record from the Oracle table

Hello All, I'm trying to spool an oracle table data into a csv file on unix server but the complete record is not being extracted. The record is almost 1000 characters but only 100 characters are being extracted and rest of the data getting truncated. I'm setting below options : SET... (4 Replies)
Discussion started by: venkat_reddy
4 Replies

9. Shell Programming and Scripting

Append date to sql*plus spool (log) file in shell script

SQL*Plus version : 11.2.0.4 OS : Oracle Linux 6.5 SQL*Plus is a client application to connect to oracle database. The log file for this tool is generated via spool command as shown below. I am trying to append date ( $dateString ) to spool file as shown below. $ cat test2.sh #!/bin/bash... (4 Replies)
Discussion started by: kraljic
4 Replies
TABLIX(1)						       Tablix User's Manual							 TABLIX(1)

NAME
tablix2_test - Tablix testing framework front-end SYNOPSIS
tablix2_test command options file DESCRIPTION
Tablix is a powerful free software kernel for solving general timetabling problems. It uses a coarse-grained parallel genetic algorithm in combi- nation with other techniques to construct sensible timetables from XML formatted problem descriptions. Tablix can run on a single host as well as on a heterogeneous parallel virtual machine using PVM3. Tablix testing framework provides a way to write simple automated tests that verify if a module and/or kernel is working as expected. Framework is composed of a special export module export_ttf.so and a utility program tablix2_test. Each automated test case is stored in a single file with the standard Tablix XML configuration syntax and a special XML comment block containing a short program written in Scheme. tablix2_test first processes each file containing the test case with tablix or tablix2 (depending on the detected version of the XML format) and then uses export_ttf.so module to run the Scheme code included in the same file to verify if the kernel has found a correct solution. For each test case, tablix2_test reports one of the following results: passed File contained XML syntax for the 0.2.x branch of kernels. tablix2 found a solution to the test problem and Scheme code confirmed that it is correct. passed (old syntax) File contained XML syntax for the 0.1.x branch of kernels. tablix found a solution to the test problem and Scheme code confirmed that it is cor- rect. skipped tablix or tablix2 executable was not found. Test problem was skipped. FAILED (tablix crashed) Tablix did not find a solution to the test problem. The reason can be a syntax error in the XML configuration file, an error in the module or a kernel crash. See any other displayed error messages for details. FAILED (most likely scheme syntax error) Scheme interpreter returned an error. The reason can be a syntax error or a bug in the Scheme code block. See any other displayed error messages for details. FAILED (ttf test failed) Tablix found a solution to the test problem but Scheme code did not confirm it. FAILED (unknown error) Tablix returned an unknown return value. You are probably running an outdated tablix2_test. Since tablix or tablix2 is run as part of the process, pvmd daemon must be running and be configured properly before running tablix2_test OPTIONS
tablix2_test --file ";OPTIONS" FILE Perform once a single test stored in the XML configuration file FILE. OPTIONS parameter is mandatory and contains options that will be passed to the tablix or tablix2 process. tablix2_test --dir ";OPTIONS" DIRECTORY Perform once all tests stored in XML configuration files in the directory DIRECTORY. OPTIONS parameter is mandatory and contains options that will be passed to the tablix or tablix2 process. tablix2_test --multi-file N ";OPTIONS" FILE Same as --file but performs each test N times. Test is considered passed only none of N repetitions of the test fail. tablix2_test --multi-dir N ";OPTIONS" DIRECTORY Same as --dir but performs each test in the directory N times. Test is considered passed only none of N repetitions of the test fail. EXAMPLES
To perform an exhaustive test of all kernel features and all modules in the distribution, run the following command from the top of the Tablix source tree: tablix2_test --multi-dir 7 "" ttf/tests A correctly working Tablix installation should pass all tests stored in the ttf/tests/ subdirectory except the error-1.xml, error-2.xml and error-3.xml tests which verify that the testing framework is correctly reporting errors. BUGS
tablix2_test utility depends on a number of common UNIX programs (mktemp, grep, sed, awk, ...) that may not be available on all systems. The script is not currently capable of properly detecting if any required programs are missing. AUTHOR
Tomaz Solc (tomaz.solc@tablix.org) SEE ALSO
tablix2(1), Tablix User's Manual, Tablix modules HOWTO Tomaz Solc 2005-09-03 TABLIX(1)
All times are GMT -4. The time now is 06:19 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy