hi
i have file which hav following entries
1501,AAA,2.00
1525,AAA,2.00
1501,AAA,2.00
1525,AAA,2.00
1501,AAA,3.00
1525,AAA,3.00
1525,AAA,3.00
1501,AAA,3.00
1501,AAA,3.00
i want to have a o/p coloum wise
like
1501,AAA,13
1525,AAA,10
here 13 comes as a sum of last colum value... (6 Replies)
Hi,
I have two files. Want to make an addition of the fifth column of from both the files and redirect it to a third file.
Both files have same records except fifth field and same record should be inserted into new file having fifth field as addition of fifth fields of both files.
for... (2 Replies)
Hi All,
I have two txt files like this
File1:
no name
----------
12 aaaa
23 bbbb
55 cccc
File2
dname dno
------------
civil 33
mech 55
arch 66
Now i want to compare col1 from File and col2 from File2, if its match i want fetch all columns from... (3 Replies)
Hello All ,
I have a problem with summing of column by group
Input File -
COL_1,COL_2,COL_3,COL_4,COL_5,COL_6,COL_7,COL_8,COL_9,COL_10,COL_11
3010,21,1923D ,6,0,0.26,0,0.26,-0.26,1,200807
3010,21,192BI ,6,24558.97,1943.94,0,1943.94,22615.03,1,200807
3010,21,192BI... (8 Replies)
Scottn, m really sorry but i have not got my answer yet.
my concern is how to delete the row !!!
i have a file which has a column that is unique
i am intending to serach it and if it is there to remove the row.
the file looks like
ROLLNO,NAME ,SUB1,SUB2,SUB3,TOTAL,PERCENTAGE,RESULT... (9 Replies)
awk '{ gsub(/....=/,""); print }' want.dat >final.dat
the above awk command which removes all the chars before and including '=' on the entire row. --thats what it meant be.:)
but i need to remove text on column-wise on each row.
many thanks,
EM
---------- Post updated at 10:00 AM... (4 Replies)
Hi I have pasted sample data as below:- in data.txt
Please suggest any way out: as the 3rd field is
cat data.txt
22:37:34 STARTING abc
22:37:40 FAILURE sadn
00:06:42 STARTING asd
00:06:51 FAILURE ad
02:06:38 STARTING acs
02:06:46 FAILURE cz
04:06:35 STARTING xzc... (1 Reply)
Hi All,
I have a file with below content
01/22/2014,23:43:00,1742.8,
01/22/2014,23:43:00,1742.8,
01/22/2014,23:44:00,1749.06666666667,
01/25/2014,23:45:00,2046.45,
01/25/2014,23:43:00,1742.8,
01/25/2014,23:44:00,1749.06666666667,
01/25/2014,23:45:00,2046.45,
01/25/2014,23:43:00,1742.8,... (4 Replies)
My below code works fine if none of the columns has pipe as its content in it, If it has the pipe in any of the content then the value moves to the next column.
I wanted my code to work fine even if the column has pipe in it apart from the delimiter.
NOTE : If there is a pipe in the content... (6 Replies)
Discussion started by: nikhil jain
6 Replies
LEARN ABOUT OPENDARWIN
begin
BEGIN(7) SQL Commands BEGIN(7)NAME
BEGIN - start a transaction block
SYNOPSIS
BEGIN [ WORK | TRANSACTION ] [ transaction_mode [, ...] ]
where transaction_mode is one of:
ISOLATION LEVEL { SERIALIZABLE | REPEATABLE READ | READ COMMITTED | READ UNCOMMITTED }
READ WRITE | READ ONLY
DESCRIPTION
BEGIN initiates a transaction block, that is, all statements after a BEGIN command will be executed in a single transaction until an
explicit COMMIT [commit(7)] or ROLLBACK [rollback(7)] is given. By default (without BEGIN), PostgreSQL executes transactions in ``autocom-
mit'' mode, that is, each statement is executed in its own transaction and a commit is implicitly performed at the end of the statement (if
execution was successful, otherwise a rollback is done).
Statements are executed more quickly in a transaction block, because transaction start/commit requires significant CPU and disk activity.
Execution of multiple statements inside a transaction is also useful to ensure consistency when making several related changes: other ses-
sions will be unable to see the intermediate states wherein not all the related updates have been done.
If the isolation level or read/write mode is specified, the new transaction has those characteristics, as if SET TRANSACTION [set_transac-
tion(7)] was executed.
PARAMETERS
WORK
TRANSACTION
Optional key words. They have no effect.
Refer to SET TRANSACTION [set_transaction(7)] for information on the meaning of the other parameters to this statement.
NOTES
START TRANSACTION [start_transaction(7)] has the same functionality as BEGIN.
Use COMMIT [commit(7)] or ROLLBACK [rollback(7)] to terminate a transaction block.
Issuing BEGIN when already inside a transaction block will provoke a warning message. The state of the transaction is not affected. To
nest transactions within a transaction block, use savepoints (see SAVEPOINT [savepoint(7)]).
For reasons of backwards compatibility, the commas between successive transaction_modes can be omitted.
EXAMPLES
To begin a transaction block:
BEGIN;
COMPATIBILITY
BEGIN is a PostgreSQL language extension. It is equivalent to the SQL-standard command START TRANSACTION [start_transaction(7)], whose ref-
erence page contains additional compatibility information.
Incidentally, the BEGIN key word is used for a different purpose in embedded SQL. You are advised to be careful about the transaction
semantics when porting database applications.
SEE ALSO
COMMIT [commit(7)], ROLLBACK [rollback(7)], START TRANSACTION [start_transaction(7)], SAVEPOINT [savepoint(7)]
SQL - Language Statements 2010-05-14 BEGIN(7)