Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FAQ questions / points that need better explanation #27

Open
DASpringate opened this issue Jul 10, 2014 · 1 comment
Open

FAQ questions / points that need better explanation #27

DASpringate opened this issue Jul 10, 2014 · 1 comment

Comments

@DASpringate
Copy link
Member

On downloading:

  • Codelist error: Not all required headings are present (Or using incorrect delimiter)

Usually means that you are uploading a csv but there are also commas in the body of the text (typically in the description column). Try doing find/replace in excel to replace commas with semi-colons.

@DASpringate
Copy link
Member Author

Non-unicode characters in the uploading file cause an internal server error

traceback:

Traceback (most recent call last):

File "/webapps/envs/medcodes/lib/python2.7/site-packages/django/core/handlers/base.py", line 115, in get_response
response = callback(request, _callback_args, *_callback_kwargs)

File "/webapps/envs/medcodes/lib/python2.7/site-packages/django/contrib/auth/decorators.py", line 25, in _wrapped_view
return view_func(request, _args, *_kwargs)

File "/webapps/envs/medcodes/lib/python2.7/site-packages/django/utils/decorators.py", line 91, in _wrapped_view
response = view_func(request, _args, *_kwargs)

File "/webapps/medcodes/medcodes/apps/codesdb/views.py", line 268, in upload_codelist
codelist_to_db(codelist_file, article_id, form.cleaned_data)

File "/webapps/medcodes/medcodes/apps/codesdb/io.py", line 153, in codelist_to_db
clinicalcode.save()

File "/webapps/envs/medcodes/lib/python2.7/site-packages/django/db/models/base.py", line 546, in save
force_update=force_update, update_fields=update_fields)

File "/webapps/envs/medcodes/lib/python2.7/site-packages/django/db/models/base.py", line 650, in save_base
result = manager._insert([self], fields=fields, return_id=update_pk, using=using, raw=raw)

File "/webapps/envs/medcodes/lib/python2.7/site-packages/django/db/models/manager.py", line 215, in _insert
return insert_query(self.model, objs, fields, **kwargs)

File "/webapps/envs/medcodes/lib/python2.7/site-packages/django/db/models/query.py", line 1675, in insert_query
return query.get_compiler(using=using).execute_sql(return_id)

File "/webapps/envs/medcodes/lib/python2.7/site-packages/django/db/models/sql/compiler.py", line 943, in execute_sql
cursor.execute(sql, params)

File "/webapps/envs/medcodes/lib/python2.7/site-packages/django/db/backends/postgresql_psycopg2/base.py", line 58, in execute
six.reraise(utils.DatabaseError, utils.DatabaseError(*tuple(e.args)), sys.exc_info()[2])

File "/webapps/envs/medcodes/lib/python2.7/site-packages/django/db/backends/postgresql_psycopg2/base.py", line 54, in execute
return self.cursor.execute(query, args)

DatabaseError: invalid byte sequence for encoding "UTF8": 0x92
HINT: This error can also happen if the byte sequence does not match the encoding expected by the server, which is controlled by "client_encoding".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant