Sponsored Content
Top Forums Shell Programming and Scripting How to write result of a query to more than 1 .csv Post 302484405 by rdcwayx on Friday 31st of December 2010 12:40:10 AM
Old 12-31-2010
Code:
your query command |split -l 50000

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

pass result from one query to another

Can any one help me how to pass the value of result of one query to another query. I to pass the value of result of 'select max(id) from a' into another query like update table set col =<value from last query> where ....; updatestaging() { xx=`$ORACLE_HOME/bin/sqlplus -s... (1 Reply)
Discussion started by: u263066
1 Replies

2. Shell Programming and Scripting

Need to compare two csv files values and write into another csv file

Hi all, Am new to scripting. So i just need your ideas to help me out. Here goes my requirement. I have two csv files 1.csv 2.csv abc,1.24 abc,1 def,2.13 def,1 I need to compare the first column of 1.csv with 2.csv and if matches then need to compare... (2 Replies)
Discussion started by: chinnahyd
2 Replies

3. Shell Programming and Scripting

How to Format the result driven from a SQL Query

Hi All, I want to format the result driven from the query into neat format. For example pls find the below code, #! /bin/sh result=' sqlplus -s uname/passwrd@DBname select no,name,address,ph_no, passport_no,salary,designation from emp_table where salary>1000; exit EOF' ... (8 Replies)
Discussion started by: little_wonder
8 Replies

4. Shell Programming and Scripting

Using Perl to query a website and parse the result

Hi, I am a JAVA programmer and I have no idea about perl. I did use it a long time ago and I don't even remember the basics. So here is my problem: In my work, I am supposed to build a simple program that opens a website (Gene Ontology)and passes my query and returns the result into a file. The... (1 Reply)
Discussion started by: chavanak
1 Replies

5. Shell Programming and Scripting

pad db2 query result to 8 bits

Hi , I am using a db2 query to get the maximum sequence number from a field.Now this value is taking up only 2 places.(i.e its less than 100).It can grow up to 3 places later but me requirement is that when i write it in a text file, it should be padded upto 8 places. Please help (1 Reply)
Discussion started by: lifzgud
1 Replies

6. UNIX for Advanced & Expert Users

Output the SQL Query result to a File

Hello Guys, This message is somewhat relates with last thread. But I need to re-write thing. I start over a little. I am stuck now and need your help. Here is my script- #! /bin/ksh export ORACLE_HOME=/opt/oracle/app/oracle/product/9.2 /opt/oracle/app/oracle/product/9.2/bin/sqlplus -s... (5 Replies)
Discussion started by: thepurple
5 Replies

7. Shell Programming and Scripting

Compare 2 file and write result

Hi friends...I have 2 files, file1.txt and reference.txt I could able to find difference using diff and following command awk 'NR == FNR { A=1; next } !A' reference.txt file1.txt above command listing data which is not in reference.txt 12.12 87 11.95 88 11.83 89 12.55 84... (12 Replies)
Discussion started by: Akshay Hegde
12 Replies

8. Programming

Query result from shell script

Hi, I wrote the below script to get the query result from a Syabase DB. isql -s -U **** -P **** SYBASE SERVERNAME USE ***(Database name in Sybase) @command.sql But im not getting the output. Can anyone help me on this (2 Replies)
Discussion started by: rohan G
2 Replies

9. Shell Programming and Scripting

Get SQL query result to file in putty

How to Get SQL query result to file in putty? I have one SQL query and I want that query output to be redirected to the file. uname -a SunOS XXX 5.8 Generic_117350-58 sun4u sparc SUNW,Sun-Fire-480R Please suggest. (7 Replies)
Discussion started by: pamu
7 Replies

10. UNIX for Beginners Questions & Answers

Not able to write SQL query output in to .csv file with shell script.

I am trying to write SQL query output into a .csv file. But in the output columns are displaying in different lines instead of coming in one line. Main Code shell script: this is my code: #!/bin/bash file="db_detail.txt" . $file rm /batch/corpplan/bin/dan.csv... (6 Replies)
Discussion started by: sandeepgoli53
6 Replies
set(1m) 																   set(1m)

NAME
set - Modifies characteristics for the DTS entity. SYNOPSIS
dtscp set characteristic ARGUMENTS
The name and value of one or more characteristics to be modified. Valid values for characteristic are described in the following list. These values are described in more detail in the description section. check interval [relative-time] courier role [role] error tolerance [relative-time] global set timeout [relative-time] local set timeout [relative-time] maximum inaccuracy [relative-time] query attempts [integer] server entry name [name] server group name [name] server principal name [name] servers required [integer] synchronization hold down [relative-time] DESCRIPTION
The set command modifies the charactistics you specify for the DTS entity. The modifiable characteristics and their values are described in the following list. Specifies the amount of time between checks for faulty servers. Applicable only for servers that have external time providers. Default: 0-01:30:00.000 Value: 0-00:00:30.000 - 10675199-02:48:05.000 Specifies a server's interaction with the set of global servers. Default: backup courier The following values are valid: The local server becomes a courier if none are available on the LAN. The local server synchronizes with the global set of servers. The local server does not synchronize with the global set of servers. Specifies the maximum separation allowed between the local clock and the computed time before synchronizations become abrupt rather than gradual (monotonic). Default: 0-00:10:00.000 Value: 0-00:00:00.500 - 10675199-02:48:05.000 Specifies the amount of time the node waits for a response to a global synchronization request before sending another request or declaring a global server to be unavailable. The number of attempts made to reach the server is controlled by the query attemps characteristic. Default: 0-00:00:15.000 Value: 0-00:00:00.000 - 0-00:10:00.000 Specifies the amount of time the node waits for a response to a local synchronization request before sending another request or declaring a server to be unavailable. The number of attempts made to reach the server is controlled by the query attemps characteristic. Note that the local set timeout value controls only the initial contact with a time provider. During this initial contact, the time provider itself determines the timeout value for actually reporting back times. This allows a time provider attached to a slow source like a modem to request that dtsd wait for a longer interval. Default: 0-00:00:05.000 Value: 0-00:00:00.000 - 0-00:01:00.000 Specifies the inaccuracy limit for the node. When the node exceeds the maximum inaccuracy setting, it attempts to synchronize. Default: 0-00:00:00.100 Value: 0-00:00:00.000 - 10675199-02:48:05.000 Specifies the number of attempts that a node makes to contact a server before the node considers the server unavailable. Default: 3 Value: 1-10 Specifies a server's CDS entry name; hostname represents the name of the system or node that is the server's client. The default setting is the recommended value. Default: /.:/hosts/hostname/dts-entity Specifies the name of the security group that DTS uses for authentication checks. DTS clerks and servers do not accept time values from DTS servers that are not included in this group. Specifies a server's principal name for authentication purposes; hostname represents the name of the system or node that is the server's client. The default setting is the recommended value. Default: /.:/hosts/hostname/self Specifies the minimum number of servers required for a synchronization. Settings of 1 or 2 may cause unreliable computed times. Default: 1 (clerks) 3 (servers) Value: 1-10 Specifies the interval a node must wait to synchronize. Also specifies synchronization frequency when a node reaches the value specified by the maximum inaccuracy characteristic. Clerks: Default: 0-00:10:00.000 Value: 0-00:00:30.000 - 01-00:00:00.000 Servers: Default: 0-00:02:00.000 Value: 0-00:00:30.000 - 01-00:00:00.000 Privilege Required You must have write permission on the ACL associated with the DTS entity in order to execute the command. NOTES
This command is replaced at Revision 1.1 by the dcecp command and may not be provided in future releases of DCE. The following two commands are obsolete. Use the replacements shown. This command is the same as set local set timeout. This command is the same as set global set timeout. EXAMPLES
The following example command sets the check interval characteristic to 30 seconds: dtscp> set check interval 00-00:00:30.000 The following example shows how to set the number of servers required before the entity can syn- chronize: dtscp> set servers required 4 The following example shows how to set the courier role for a server: dtscp> set courier role backup courier The following example command sets the error tolerance characteristic to seven minutes: dtscp> set error tolerance 0-00:07:00.000 The following example command the global set timeout characteristic to 45 seconds: dtscp> set global set timeout 0-00:00:45.000 The following example command the local set timeout characteristic to five seconds: dtscp> set local set timeout 0-00:00:05.000 The following example command sets the maximum inaccuracy characteristic to three milliseconds: dtscp> set maximum inaccuracy 0-00:00:00.300 The following example command sets the server entry name characteristic to /.:/hosts/orion/dts-entity: dtscp> set server entry name /.:/hosts/orion/dts-entity The following example command sets the server principal name characteristic to /.:/hosts/vega/dts-entity: dtscp> set server principal name /.:/hosts/vega/dts-entity The following example command sets the synchronization hold down characteristic to 15 minutes: dtscp> set synchronization hold down 0-00:15:00.000 RELATED INFORMATION
Commands: show(1m) set(1m)
All times are GMT -4. The time now is 06:33 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy