RE: [GENERAL] Re: newline character handling

2000-04-10 Thread Sampath, Krishna


maybe we need a keyword DOS|UNIX or perhaps TEXT|BINARY to tell postgresql
to pick DOS style or UNIX style line endings... 

krishna

-Original Message-
From: Michael Blakeley [mailto:[EMAIL PROTECTED]]
Sent: Saturday, April 08, 2000 12:57 PM
To: [EMAIL PROTECTED]
Subject: [GENERAL] Re: newline character handling


>  From: "Sampath, Krishna" <[EMAIL PROTECTED]>
>  To: [EMAIL PROTECTED]
>  Subject: newline character handling
>  Date: Fri, 7 Apr 2000 15:49:58 -0400
>
>  As I tried, using COPY, to import a few flat files created under Windows
>  into postgresql running on a Linux machine, I discovered that:
>  * If the last field in your record is a string, postgresql imports it,
but
>  keeps the ^M as part of the text string.
>  * If the last field is numeric, postgresql refuses to import that line
>  (because of the ^M, the field is not recognized as a number)
>
>  Once I stripped the ^M, the data bulkloaded without a problem. Perhaps
COPY
>  should be smarter and recognize the DOS-style line endings?

I'm ok with this for numerics, but against it for text. Why? Because 
I work with some binary data, and I wouldn't want the mysterious 
problem of not being able to COPY a line containing a record that's 
_supposed_ to end in ^M.

-- Mike



RE: [GENERAL] Permission denied while importing data from a file?

2000-04-10 Thread Sampath, Krishna


maybe the directory '.../somebody' does not have read permission (700?)

krishna


-Original Message-
From: Adam Ruth [mailto:[EMAIL PROTECTED]]
Sent: Monday, April 10, 2000 9:54 AM
To: [EMAIL PROTECTED]
Subject: Re: [GENERAL] Permission denied while importing data from a
file?


I've gotten that message before when users couldn't read the directory the
file is in.

--
Adam Ruth
InterCation, Inc.
www.intercation.com
"Felix Slager" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> LS,
>
> i'm trying to copy data into a table using a copy command using:
>
> COPY tabelName FROM '/somewhere/somebody/datafile.txt';
>
> I've given everybody the right to use the datafile.txt (execute, read,
> write) with an incredible chmod . Still i get the message:
>
> ERROR:  COPY command, running in backend with effective uid nr 666,
> could not open file '/somewhere/somebody/datafile.txt' for reading.
> Errno = Permission denied (13).
>
> Why? I mean how does this happen?
> Please help...
>
> Felix




RE: [GENERAL] BLOB datatype

2000-04-10 Thread Sampath, Krishna

look at the examples in the postgresql book available on the website.
 
krishna
 

-Original Message-
From: iqbal [mailto:[EMAIL PROTECTED]]
Sent: Monday, April 10, 2000 7:11 AM
To: [EMAIL PROTECTED]
Subject: [GENERAL] BLOB datatype


i have created a table having blob object but now i am  not able to insert a
picture into the table. Can you send me sql command to insert picture into
the table i need syntax. i tried through DB2IMAGE but failed to insert.
 
if there is any other method of putting image in the table, kindly send me
the same




[GENERAL] Searching www.postgresql.org - TIP

2000-04-07 Thread Sampath, Krishna


You have probably noticed that the search engine on the postgresql site has
been up and down a lot. In order to search the mailing list archives, you
can usealtavista (www.altavista.com) with the host qualifier. In addition to
your search phrase, include the qualifier "host:www.postgresql.org" (without
quotes). Then, altavista searches only this host and lists the results. 

For example, the following search produces about 14 pages.
host:www.altavista.com "date format" 

Thought this might help find information on the mailing list archives more
easily.

krishna



[GENERAL] postgresql 7.0beta2 - bugs?

2000-03-24 Thread Sampath Krishna

hi,

i just upgraded to postgresql 7.0beta2 on a i586 linux machine running
redhat 6.1.

the compile/install went without a hitch. when trying to run the
regression tests, here is what i noticed...

regress.sh:
psql does not support the -X option. not too sure what it was for in
earlier versions. so i simply deleted the option :)
command 'dropdb' was not found. changed all occurences to
'destroydb'

with these changes, all the regression tests run, but all of them fail.
seems like the actual tests are passing (ie, the sql is ok) but diff
fails. the reason seems to be  an extra blank line after each command
in the results.

is there a new suite of expected/* and resultmap for postgresql7.0? i
will help with their creation in whatever way i can...

sampath

--
Sampath Krishna, Ph.D.
285 Greenfield Road
Bridgewater, NJ 08807
Home: 908-429-0450
Work: 973-267-8830 x1987
[EMAIL PROTECTED]