Cannot import from CSV file

3,082 views
Skip to first unread message

Phyo Arkar

unread,
Nov 5, 2008, 7:50:14 AM11/5/08
to web...@googlegroups.com
Hello all;

Any one tried importing from CSV file?

I got the error unable to parse but when i try it directly via csv module in normal python it parses well.


mdipierro

unread,
Nov 5, 2008, 11:03:57 AM11/5/08
to web2py Web Framework
Do you have the first row with the column names?

Phyo Arkar

unread,
Nov 5, 2008, 2:54:50 PM11/5/08
to web...@googlegroups.com
Thanks! its ok now

somebody

unread,
Nov 17, 2008, 12:26:59 AM11/17/08
to web2py Web Framework
hi are u creating a new module/controller which allow you to export
SQL table value and save them as text file? I know that web2py has
build in CSV but i want to create a new controller which allow you to
export choosenSQL table value and save them as text file?

can you help?
thanks

mmstud

unread,
Nov 17, 2008, 1:59:41 AM11/17/08
to web2py Web Framework
Was it only column names? I tried to import csv file, got parse errors
althought i had column names... Finally i got tired of trying to
import with web2py and did import data with Navicat. Same csv file and
it worked well. But now my character encodings are wrong...

Actually i did one test, where i tried to put only column names plus
one line / row with corresponding empty values (,,,,,,,,) to csv file
and it was imported well. As said navicat understood file without
problems and i could find any errors or false amount of commas from
csv file neither.

-Marko

On Nov 5, 9:54 pm, "Phyo Arkar" <phyo.arkarl...@gmail.com> wrote:
> Thanks! its ok now
>
> On Wed, Nov 5, 2008 at 4:03 PM, mdipierro <mdipie...@cs.depaul.edu> wrote:
>
> > Do you have the first row with the column names?
>
> > On Nov 5, 6:50 am, "Phyo Arkar" <phyo.arkarl...@gmail.com> wrote:
> > > Hello all;Was

voltron

unread,
Dec 9, 2008, 11:32:46 AM12/9/08
to web2py Web Framework
I am still having problems with CSV import just like the poster of
this thread. All the colum headers are ok, and the file imports well
usíng SQLite manager, Sqliteman , MS Excel and other tools. Is there
anyone that has had some success?


Thanks

mdipierro

unread,
Dec 9, 2008, 12:11:20 PM12/9/08
to web2py Web Framework
Can I see the model and the file?

Massimo
Reply all
Reply to author
Forward
0 new messages