We are using sybase data base and we have the data base name called MasterDB. The data baase MasterDB contains 100's of tables like sample1, sample2, sample3...etc...sample100
To take the count of every table we have to execute the following commands
use MasterDB //DB name
go //execute command in sybase
select count(*) from sample1 // command to find the count of table
go //execute the command
This is the way to take count. Likewise manually we have to take 100 tables count...we have to automates this though shell scripts.
What I did here is, I write all table names in the flat file and trying to read the flat files from the scripts
i know its incorrect logic..pls help me onthis
Last edited by Yogesh Sawant; 04-01-2009 at 02:40 PM..
Reason: added code tags
We are using sybase data base and we have the data base name called MasterDB. The data baase MasterDB contains 100's of tables like sample1, sample2, sample3...etc...sample100
To take the count of every table we have to execute the following commands
use MasterDB //DB name
go //execute command in sybase
select count(*) from sample1 // command to find the count of table
go //execute the command
This is the way to take count. Likewise manually we have to take 100 tables count...we have to automates this though shell scripts.
What I did here is, I write all table names in the flat file and trying to read the flat files from the scripts
Please put code inside [code] tags.
Quote:
Your code is not wrong, but grouping commands is neater:
Hi,
How to add trailer record at the end of the flat file in the unix ksh shell scripting
can you please let me know the procedure
Regards
Srikanth (3 Replies)
Hi Friends,
I would like to read all the record from one txt file to other file txt
For example I have two txt file a.txt and b.txt. I need to read a.txt record by record and I need add the system date @ end of each record before moving it to b.txt. Could you please share the coding for... (4 Replies)
I need some help to create a script that can do the following:
I have two flat files with one column that should link the two files' information into one record:
1st Flat File - 3 columns, multiple rows:
orderid, Jobnumber, Ordernumber
2nd Flat File - 2 columns, multiple rows:
... (4 Replies)
I am new to shell scripting and I have to to the following
I have a flat file with storename(lenth 20) , emailaddress(lenth 40), location(15). There is NO delimiters in that file.
Like the following str00001.txt
StoreName emailaddress location... (3 Replies)
We are using sybase data base and we have the data base name called MasterDB. The data baase MasterDB contains 100's of tables like sample1, sample2, sample3...etc...sample100
To take the count of every table we have to execute the following commands
use MasterDB //DB name
go //execute... (1 Reply)
Hello Friends
I am new to this forum and this is my first post.
I have to write a script in which i have to read data from a configuration ( .cfg) file. And also i have to execute/call some already written scripts from this script.
Can you people plpease help me on this regards.
Thanks... (5 Replies)
i have done a coding in shell scripting which reads a file line by line and does something....it takes more than 30 seconds to execute for a single file. when i do the same with perl scripting it takes less than a second.
is that shell scripting is not efficient while working with large number of... (1 Reply)
Hello There..
I came to a situation where I need to write flat files using shell scripts, I need to pull the records from the oracle database and create the flat file, This process should be automated.
Can any shell script expert out here to help me.. please..
Will be really glad to... (3 Replies)
Hi all,
How to create Flat Files using Unix Shell Script. The Script is supposed to be sheduled to run at a particular time?
Thanks in advance
Appu (4 Replies)