LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 09-04-2011, 11:36 AM   #1
dhirendrs
Member
 
Registered: Nov 2009
Posts: 45

Rep: Reputation: 15
I am using plink as below.



I am running below in .bat file

As below .
plink.exe -ssh -pw fks123 imfldb@10.0.7.58 /data/DailyReport/daily_report.sh

Daily_report.sh

psql -h 10.0.7.58 -p 5432 -U imfldb -f '/data/DailyReport/daily_report_qry.sql' -F -d omniflowuat > /data/DailyReport/Input/daily_report$DATE.data

Now my question is daily_report$date.data have
delimiter sign not opening as excel file,

i want to modified the script which open as .xls files.

 
Old 09-05-2011, 09:23 PM   #2
ta0kira
Senior Member
 
Registered: Sep 2004
Distribution: FreeBSD 9.1, Kubuntu 12.10
Posts: 3,078

Rep: Reputation: Disabled
You haven't specified a field separator for the -F psql option. ',' might be a good choice.
Kevin Barry
 
Old 09-07-2011, 09:14 AM   #3
dhirendrs
Member
 
Registered: Nov 2009
Posts: 45

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by ta0kira View Post
You haven't specified a field separator for the -F psql option. ',' might be a good choice.
Kevin Barry

Can you please describe the exact query?
 
Old 09-07-2011, 10:25 AM   #4
ta0kira
Senior Member
 
Registered: Sep 2004
Distribution: FreeBSD 9.1, Kubuntu 12.10
Posts: 3,078

Rep: Reputation: Disabled
Quote:
Originally Posted by dhirendrs View Post
Can you please describe the exact query?
I'm not sure what that means, since it's your query.

The -F option requires an argument, which is used to specify a field separator. If you want a field separator, specify it by putting an argument after -F. Otherwise, remove the -F option from your psql call. Since you're trying to open the output as a spreadsheet you might want to use -F ',' to separate the fields with a comma.
Kevin Barry
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
start gqview from windows over ssh with putty/plink Peterken Linux - Newbie 4 01-11-2010 07:51 PM
plink command venkat_k Linux - General 6 12-21-2009 08:57 AM
XMing/PLink won't cooperate... richardh1970 Linux - Software 1 10-21-2008 08:09 AM
xming, plink, and startkde not working kavius General 5 07-18-2008 10:48 AM
is there a plink for linux ? alix123 Programming 1 05-08-2007 01:47 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 01:11 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration