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

WFS 2.0 wrong extension response to a spatialite zip request #4933

Closed
aperi2007 opened this issue Jun 2, 2014 · 3 comments
Closed

WFS 2.0 wrong extension response to a spatialite zip request #4933

aperi2007 opened this issue Jun 2, 2014 · 3 comments
Assignees

Comments

@aperi2007
Copy link

@aperi2007 aperi2007 commented Jun 2, 2014

Mapserver use wrong extension in a response to a spatialite zipped request.

Starting from this setting:

OUTPUTFORMAT
NAME "SPATIALITE"
DRIVER "OGR/SQLITE"
MIMETYPE "application/zip"
FORMATOPTION "DSCO:SPATIALITE=YES"
FORMATOPTION "STORAGE=memory"
FORMATOPTION "FORM=zip"
FORMATOPTION "FILENAME=result.db.zip"
END

The zip resulted will not contain a file .sqlite but instead a file with zip extension.
But this is not a zip file.It is instead a real spatialite db. The MapServer has named its extension .zip instead of .sqlite

@tbonfort
Copy link
Member

@tbonfort tbonfort commented Jun 3, 2014

the FILENAME key is used to create the OGR datasource, so it should probably be set to result.db instead of result.db.zip. However when using zipped form, we should probably append ".zip" to the filename of the Content-Disposition header. cc @rouault

@rouault
Copy link
Contributor

@rouault rouault commented Jun 3, 2014

@tbonfort I will take after this bug. My intent is, when FORM=zip, to analyse the filename. If it is of the kind foo.bar.zip, then the OGR datasource will be created with foo.bar as a name, and the result will be zipped in foo.bar.zip. If FILENAME is not specified or just as foo.zip then the OGR datasource will be named result.dat.

@rouault rouault self-assigned this Jun 3, 2014
rouault added a commit to mapserver/msautotest_DEPRECATED that referenced this issue Jun 11, 2014
rouault added a commit that referenced this issue Jun 11, 2014
…xt.zip", use basename.ext as the name of the OGR datasource (#4933)
rouault added a commit to mapserver/docs that referenced this issue Jun 11, 2014
rouault added a commit to mapserver/msautotest_DEPRECATED that referenced this issue Jun 11, 2014
rouault added a commit that referenced this issue Jun 11, 2014
@jratike80
Copy link

@jratike80 jratike80 commented Nov 2, 2015

I believe that this one can be closed like the referenced #4856.

@jratike80 jratike80 closed this Nov 2, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants
You can’t perform that action at this time.