On Thursday, August 6, 2015 at 6:39:22 AM UTC-7, Sai Harsh Tondomker wrote:
>
> My db.py is 
>
> db.define_table("Questions",
>   Field('quesno','integer',notnull=True,unique=True),
>   Field('question', 'text'),
>   Field('qupload','upload',label='Upload Image'),
>   Field('optionA', 'string',label='optionA'),
>   Field('optionB', 'string',label='optionB'),
>   Field('optionC', 'string',label='optionC'),
>   Field('optionD', 'string',label='optionD'),
>   Field('answer', 'string'),
>   )
>
> And error after uploading file is
> unable to parse csv file 
> "UNIQUE constraint failed: Questions.quesno"
>
> What I need to do for these.
> Please help me to solve the problem.
> Waiting for your response.
>

Does your CSV file have 2 (or more) entries with the same value in the 
quesno column?  If not, do the values match any that already in the DB?

/dps

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to