Sponsored Content
Top Forums Shell Programming and Scripting Append transaction header lines to same transaction's detail lines Post 302430491 by pseudocoder on Thursday 17th of June 2010 10:38:24 PM
Old 06-17-2010
Code:
$ perl -nle 'if ($a == 0 && $_ !~ /^F/)  { push @x, $_; $a=1; next; }
             if ($a == 1 && $_ !~ /^TT/) { print "$_, @x";          }
          elsif ($a == 1 && $_ =~ /^TT/) { @x=(), $a=0;             }' file

 

8 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

average transaction time

Hi all, I have large daily log file(s) that hold the times for requests and responses on different system requests. What I want to do is work out average transaction times for the day (one log = one day). The problem I'm having is figuring out how to skip rows, i've sorted the output by uniq... (2 Replies)
Discussion started by: nhatch
2 Replies

2. UNIX and Linux Applications

Got Errors while sending a transaction through ESB

We are getting below error when processing a transaction through ESB. I work for SOA admin and checked the JCA connection is working fine also code also working fine in other envs. An unhandled exception has been thrown in the ESB system. The exception reported is:... (1 Reply)
Discussion started by: KuldeepSinghTCS
1 Replies

3. Linux

YUM HANGS AT RUNNING TRANSACTION TEST

Hi When i trying to update using yum, hangs at Running transaction test. # yum update yum Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * addons: ftp.oss.eznetsols.org * extras: ftp.oss.eznetsols.org * base: ftp.oss.eznetsols.org * updates:... (2 Replies)
Discussion started by: anil8103
2 Replies

4. Solaris

Concept of ZFS transaction semantics

HI, Can anyone explain me the concept behind ZFS transactional semantics (either a transaction is entirely commited or it is not)? so data and disk failures are reduced. (5 Replies)
Discussion started by: Revathi@1
5 Replies

5. UNIX for Dummies Questions & Answers

Rolling back SQL transaction

Can some one help me related to .sql file issue. I have a .sqlfile and tried to read the file thru unix. In the .sqlfile I have error rows as well and when error comes I dont want to proceed further and need to roll back all the transactions. sample .sql file below insert into test... (2 Replies)
Discussion started by: sri_aue
2 Replies

6. Shell Programming and Scripting

Process only files which have completed in transaction

Hi , I have a situation where I have to Process files ( move , edit or rename ) in a folder ..... This folder is a FTP folder and Files keep coming in when they are available ... So I should perform my actions on those which which completed transaction .. . Is there a way to identify a... (3 Replies)
Discussion started by: chillblue
3 Replies

7. Programming

Difference between BEGIN TRANSACTION & START TRANSACTION?

What's the difference between BEGIN TRANSACTION vs START TRANSACTION? Also goes for COMMIT TRANSACTION vs COMMIT? (0 Replies)
Discussion started by: dan139
0 Replies

8. AIX

Transaction based resources

How do I determine the resources needed based on volume of transactions. By resources I mean, the cores, memory etc. Is there a way to arrive at that value? (1 Reply)
Discussion started by: ggayathri
1 Replies
af_transact(3)						    Attribute Filesystem (AtFS) 					    af_transact(3)

NAME
af_transaction, af_commit, af_abort - a simple transaction mechanism for AtFS SYNOPSIS
#include <atfs.h> int af_transaction (void) int af_commit (void) int af_abort (void) DESCRIPTION
These functions implement a simple transaction mechanism for AtFS. A transaction starts with calling af_transaction. All changes to exist- ing ASOs performed hereafter have no immediate permanent effect. They rather get into effect, when the transaction is ended. Calling af_commit ends the transactions and causes all changes to be saved to disk. af_abort aborts the transaction without saving the changes. These will then be discarded. Only modification of the state of existing source ASOs will be deferred. Creation or deletion of ASOs have immediate effect, regardless if a transaction is in effect or not. Additionally, all operations on derived ASOs (all operations on the derived object cache) are not affected by the transaction. All archive files that are to be changed when the transaction is finished are locked until the end of the transaction. The lock prevents all other applications to perform any modifications on the archive file. You should make sure, that ending a transaction should never be dependent on the successful termination of another application (deadlock danger). DIAGNOSTICS
Upon error, -1 is returned and af_errno is set to the corresponding error number. BUGS
Changes to the contents of busy versions have immediate effect. AtFS-1.71 Fri Jun 25 14:33:21 1993 af_transact(3)
All times are GMT -4. The time now is 07:39 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy