Dear Mitch,
First, I would to sincere thanks for your clues on this point.
I would also like to have some questions to you as below, please try to
support at the most possibility.
-
I have tried to find the XML which uploaded from the ODK Collect
to ODK Aggregate, unfortunately, I was not luck in this job. So, I thought
that this type of XML file has not been sending to the Aggregate server. My
questions on this point are: (a) if I am wrong, where is the XML file is
stored in the ODK Aggregate? and (b) if I am right, how does the ODK
Collect (with what widget?) to escape this XPath to the PostgreSQL database
with ODK Aggregate?
*2. *This point might be more time-consuming answer for you, but I
still want to understand more clear. I have detailed look at the PostgreSQL
database (all columns in all tables) but still not find some fields in the
string: formid[@version=null and
@uiVersion=null]/topElement[@key=idvalue]
-
@version
-
@uiVersion
-
topElement
-
key=idvalue.
Could you please tell me where I can find it in the database?
Thank you so much in advance.
Thanh
From: opendatakit@googlegroups.com [mailto:opendatakit@googlegroups.com]
*On Behalf Of *Mitch Sundt
Sent: Tuesday, November 17, 2015 2:04 AM
To: ODK Community opendatakit@googlegroups.com
Subject: Re: [ODK Community] ODK Aggregate Internal Server Error (500)
because of PostgreSQL trigger
The URL for the binary attachment is constructed from the XPath expression
for that file.
e.g., from the opendatakit demo site:
https://opendatakit.appspot.com/view/binaryData?blobKey=Birds[%40version%3Dnull+and+%40uiVersion%3Dnull]%2Fnm[%40key%3Duuid%3A49def8d0-1357-41b2-956c-a270e2d91f62]%2Frepeat_observation[%40ordinal%3D1]%2Fimage&previewImage=true
Everything after ? is an &-separated key-value list of arguments.
The previewImage=true argument produces a thumbnail.
The identifier for the image is the *blobKey=... *argument:
Birds%5B%40version%3Dnull+and+%40uiVersion%3Dnull%5D%2Fnm%5B%40key%3Duuid%3A49def8d0-1357-41b2-956c-a270e2d91f62%5D%2Frepeat_observation%5B%40ordinal%3D1%5D%2Fimage
This is a URL-escaped XPath:
Birds[@version=null and
@uiVersion=null]/nm[@key=uuid:49def8d0-1357-41b2-956c-a270e2d91f62]/repeat_observation[@ordinal=1]/image
The first portion of this is:
formid[@version=null and @uiVersion=null]/topElement[@key=idvalue]
topElement is the root element of the XForms instance.
After that, it is an XPath to the image file. If you have repeat groups,
the specific repeat group is identified with [@ordinal=nnn], where nnn is
1, 2, ....
On Sun, Nov 15, 2015 at 5:16 PM, Yaw Anokwa yanokwa@nafundi.com wrote:
Sounds like good progress!
What you see on the wiki is what exists as far as DB structure. Is
there a specific question we could help answer?
Yaw
Need ODK consultants? Nafundi provides form design, server setup,
in-field training, and software development for ODK. Go to
https://nafundi.com to get started.
On Sun, Nov 15, 2015 at 6:16 PM, Văn Thanh Nguyễn thanh.dbpfms@gmail.com wrote:
Dear Mitch and All,
Finally, I got the SQL to query spatial data from PostgreSQL, using
ST_GeomFromText (text, integer). Now I can reduce 2 big steps for users
to
use QGIS to readd data from ODK Collect.
However, my next concerns are how to produce image links as it is
produced
in the exported CSV by ODK Aggregate (I prefer to use PostgreSQL
function(s)
to create links). I have tried to have a look at ODK Aggregate Database
Structure, but actually, not much information.
Do you all can blow some guides?
Thank you very much in advance.
Thanh
Vào 02:13:05 UTC+7 Thứ Ba, ngày 10 tháng 11 năm 2015, Mitch Sundt đã
viết:
Sorry, no.
GIS systems are not my area of expertise.
On Sat, Nov 7, 2015 at 7:42 PM, Nguyễn Văn Thanh thanh....@gmail.com wrote:
Thank you very much Mitch,
I’ve found the problem before getting your message. The log can be
found
easily in (my case, Windows 10 64 bit) “C:\Program
Files\PostgreSQL\9.2\data\pg_log”. Yes, it is the INSERT permission on
the
database.
Anyway, I am stuck at converting coordinates data (geo_shape) to
geometry. I used ST_GeomFromText but not success at this moment. Do
you all
have any suggestion?
Regards,
From: opend...@googlegroups.com [mailto:opend...@googlegroups.com] On
Behalf Of Mitch Sundt
Sent: Saturday, November 7, 2015 1:36 AM
To: ODK Community opend...@googlegroups.com
Subject: Re: [ODK Community] ODK Aggregate Internal Server Error (500)
because of PostgreSQL trigger
Look in your Tomcat logs for more detailed error messages.
You might need to configure logging on Tomcat to get it to produce
detailed logs. The ODK Aggregate code should log errors of this kind,
but I
have noticed that our recent Tomcat 6 deployments did not produce the
expected (and volumeous) tomcat6.stdout log.
Looking at your files, I believe the trigger insert is failing and
causing the ODK Aggregate to fail.
The root cause is likely that the thanhnv user that is used by ODK
Aggregate does not have insert permissions on the polygon table owned
by
postgres
On Fri, Nov 6, 2015 at 12:02 AM, Văn Thanh Nguyễn <thanh....@gmail.com wrote:
Dear All,
First, I do apologies if I am missing relevant posts.
I am now deploying a system as below:
- Server side:
- Client side: GeoODK 1.9 (GitHub) on Android 5.0.1
This system operate smoothly if I satisfy with "Export to .CSV" on ODK
Aggregate interface then convert from .CSV to Shapefile using XLS
GeoConverter.
However, it is quite complicated for user to operate many steps.
My idea is to set up database triggers to copy data from the ODK
Aggregate tables into your PostGIS tables, so that users can use QGIS
to
connect directly to PostGIS to read data, which saves at least two
complicated steps.
Anyway, my problem now is, every time I place the trigger into the ODK
Aggregate table (one for test first), both uploading data from client
(GeoODK) and also "Manually Upload Submission Data" in Web-based ODK
Aggregate, both ways producing error. Trigger SQL itself may not be any
problem since I can query it and produce a good result. If I remove the
trigger from ODK Aggregate table, data uploading is no error.
Attachments are some detailed information with screenshots and table
structure.
Does anybody here have same problem and have a solution? Or is it a bug
in ODK Aggregate?
Any help are warmly welcome.
Thank you very much in advance.
--
Post: opend...@googlegroups.com
Unsubscribe: opendatakit...@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en
You received this message because you are subscribed to the Google
Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send
an
email to opendatakit...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Mitch Sundt
Software Engineer
University of Washington
mitche...@gmail.com
--
Post: opend...@googlegroups.com
Unsubscribe: opendatakit...@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en
You received this message because you are subscribed to a topic in the
Google Groups "ODK Community" group.
To unsubscribe from this topic, visit
https://groups.google.com/d/topic/opendatakit/_dV2b7UetWk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to
opendatakit...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Post: opend...@googlegroups.com
Unsubscribe: opendatakit...@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en
You received this message because you are subscribed to the Google
Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send
an
email to opendatakit...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Mitch Sundt
Software Engineer
University of Washington
mitche...@gmail.com
--
Post: opendatakit@googlegroups.com
Unsubscribe: opendatakit+unsubscribe@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en
You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Post: opendatakit@googlegroups.com
Unsubscribe: opendatakit+unsubscribe@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en
You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Mitch Sundt
Software Engineer
University of Washington
mitchellsundt@gmail.com
--
Post: opendatakit@googlegroups.com
Unsubscribe: opendatakit+unsubscribe@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en
You received this message because you are subscribed to a topic in the
Google Groups "ODK Community" group.
To unsubscribe from this topic, visit
https://groups.google.com/d/topic/opendatakit/_dV2b7UetWk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to
opendatakit+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Post: opendatakit@googlegroups.com
Unsubscribe: opendatakit+unsubscribe@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en
You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.