Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^2: Add Null values to my FlatFile

by lakeTrout (Scribe)
on Nov 26, 2007 at 21:34 UTC ( [id://653092]=note: print w/replies, xml ) Need Help??


in reply to Re: Add Null values to my FlatFile
in thread Add Null values to my FlatFile

Hi, thanks for taking a look. The log file prints everything in sequence, something like this:
Head1 Head2 Head3 Head4 Head5 val1 val2 val9 val10 val1
what I want is this:
Head1 Head2 Head3 Head4 Head5 ... Head9 val1 val2 val9
where values 3-8 are null, they don't print. I'll try you suggestion and see what that gives me.

Thank you!

UPDATE:
adding: print LOGFILE "/$key/".$FORM{$key}."\n"; instead of what I have already doesn't add the fields with no value, it just prints element on a new line, like it's a new record in the flat file

Replies are listed 'Best First'.
Re^3: Add Null values to my FlatFile
by apl (Monsignor) on Nov 26, 2007 at 22:51 UTC
    I was vague; my apologies. I suggested the new print as a debugging aid. It wasn't intended as a solution to the problem.

    Having seen the follow-up, I'd agree with aquarium; if the value is NULL, force it to a blank or a fixed string.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://653092]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (4)
As of 2024-04-25 02:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found