05-27-2010
Are you sure you mean an extra newline at the end of the file, as in, two? Or just one newline at the end of the file? One newline at the end of the file may look like an extra blank line but is really just one character. Many text editors won't even create a text file without at least one newline at the end of file.
Even gcc gives a warning about no newline at the end of the file(Not an error mind you, just a warning), it may be traditional/standard behavior. On one hand it's a stupid thing to be picky about, on the other hand it's a silly thing to quibble about either -- not hard to add one newline to one file once and be done with it.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi
i have a variable with lots of tokens seperated with spaces.
e.g VAR="ABC DEF GHSD GHQS TUTSD JHDTQ QDHQ CDQKDGQ WQUTQD DQUTQD DQJGDQ QDTQD WDQUTQDU QDUGQD QDJGQD DQUTDUQ QDUIDTQ"
i want to separate all of the above tokens and call a script with each of the token e.g sh script.sh <TOKEN>... (4 Replies)
Discussion started by: skyineyes
4 Replies
2. UNIX for Advanced & Expert Users
Hi,
I need help with using an awk or sed filter on the below line
ALTER TABLE "ACCOUNT" ADD CONSTRAINT "ACCOUNT_PK" PRIMARY KEY ("ACCT_ID") USING INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255 STORAGE(INITIAL 65536 FREELISTS 1 FREELIST GROUPS 1) TABLESPACE "WMC_DATA" LOGGING ENABLE
Look for... (1 Reply)
Discussion started by: rajan_san
1 Replies
3. UNIX for Dummies Questions & Answers
Hi Experts,
I want to print the lines whose third field in non-empty/blank space.
i.e.
INPUT FILE/B]
dcdccghjrry0yd cont
dcdccttrk820529 cont rdekedfsSCr
dcdccttrdky2d0y cont rdekedfsSC2 ... (3 Replies)
Discussion started by: krao
3 Replies
4. Shell Programming and Scripting
Hi,
Can you please tell me how to add empty columns at the end csv file?
Currently there are 6 columns in the csv file. I want to add 35 empty columns at the end of this csv file.
Thanks,
Tushar (17 Replies)
Discussion started by: Tushar Bendale
17 Replies
5. UNIX for Advanced & Expert Users
Hi All,
I am facing an issue in one of the use cases that I am trying to implement.
I am getting a purchase order from one of the trading partners through Oracle B2B.
B2B forwards this B2BM (B2B message ) to AIAB2BInterface. From AIAB2BInterface my BPEL process gets invoked, which in turn... (1 Reply)
Discussion started by: mayank2211
1 Replies
6. UNIX for Dummies Questions & Answers
I'm trying to remove all of the empty lines at the end of a Tab delimited file. They have no data just tabs.
I've tried may things, here are a couple:
sed /^\t.\t/d File1 > File2
sed /^\t{44}/d File1 > File2
What am I missing? (9 Replies)
Discussion started by: SirHenry1
9 Replies
7. Solaris
Hi all,
I have written the following program and run on both T5440 and T5220 on same OS version. I found that T5540 server takes more time than T5220. Please find below the details.
test1.cpp
#include <iostream>
#include <pthread.h>
using namespace std;
#define NUM_OF_THREADS 20... (17 Replies)
Discussion started by: sanjay_singh85
17 Replies
8. Linux
I have a .CSV file (lets say named as file.csv) with numeric and string values. The string might contain commas hence they are enclosed in double quotes as in the below format.
column1,column2,column3,column4,column5,column6,column7
12,455,"string, with, quotes, and with, commas, in... (3 Replies)
Discussion started by: dhruuv369
3 Replies
9. Shell Programming and Scripting
Hello,
I need a program that read a file line by line and prints out lines 1, 2 & 3 after an empty line... An example of entries in the file would be:
SRVXPAPI001 ERRO JUN24 07:28:34 1775
REASON= 0000, PROCID= #E506 #1065: TPCIPPR, INDEX= 003F
... (8 Replies)
Discussion started by: Ferocci
8 Replies
10. UNIX for Dummies Questions & Answers
Hi Folks,
I have a requirement to develop a shell script. PFB my requirement,
Requirement:
I need to check an empty line after the end of each header in respective file and if a empty line is present simply echo file OK and if empty line is not present echo "Adding empty line" and add an... (6 Replies)
Discussion started by: tpk
6 Replies
LEARN ABOUT HPUX
fegetenv
fegetenv(3M) fegetenv(3M)
NAME
fegetenv() - get floating-point environment
SYNOPSIS
HP Integrity Server Only
PA-RISC Only
DESCRIPTION
The function stores the current floating-point environment in the object pointed to by the argument envp.
To use this function, compile either with the default option or with the and options.
Make sure your program includes
For Integrity servers, specify on the compiler command line or place the call to this function under the effect of an affirmative pragma:
If the pragma is placed outside of any top-level declarations in a file, the pragma will apply to all declarations in the compilation fol-
lowing the pragma until another pragma is encountered or until the end of the file is reached.
If the pragma is placed at the beginning of a block (compound statement), the pragma will apply until another pragma is encountered or
until the end of the block is reached.
For PA-RISC, you might need to use the +Onomoveflops compiler option in order to prevent optimizations that can undermine the specified
behavior of this function.
Link in the math library by specifying on the compiler or linker command line.
For more information, see the at the following site:
RETURN VALUE
Integrity Server Only
This function always returns 0, indicating that a representation of the current environment was successfully stored.
PA-RISC Only
None.
ERRORS
No errors are defined.
EXAMPLES
Store the current floating-point environment:
SEE ALSO
feholdexcept(3M), fesetenv(3M), feupdateenv(3M), fenv(5).
STANDARDS CONFORMANCE
: ISO/IEC C99 (including Annex F, "IEC 60559 floating-point arithmetic")
fegetenv(3M)