[Qgis-user] Inefficient SQL

chris hermansen clhermansen at gmail.com
Fri Jul 3 07:11:31 PDT 2020


Paul and list,

On Fri, Jul 3, 2020, 05:11 Paul Wittle <paul.wittle at dorsetcouncil.gov.uk>
wrote:

> Hi,
>
>
>
> We noticed that one of our users was accidentally sending inefficient (or
> possibly just massive) SQL statements to the Oracle database. I need to do
> more work to try and replicate the behaviour but is anyone familiar with
> how it can happen?
>
>
>
> The query is in the form of select [statement] from table where ID = :a OR
> ID = :b … OR ID = :xxab
>

Could this be an Oracle table joined by QGIS to a (say) shapefile with the
user selecting a bunch of records (maybe selecting all; or selecting a few
,then inverting the selection; or selecting all records in a bounding box)
which is seen on the Oracle end as such a select?

I don't know this for a fact but it seems plausible. I would think it's
going to be a bunch of OR operators or an IN () with a long list.

>
>
> We wondered why that would happen as normally you would just do a spatial
> query or perhaps do that for a small number of rows but it seemed to be
> doing it for a large number of rows.
>
>
>
> Any tips to what might be the cause would help me to replicate the issue;
> my working theory is trying to load too many features in the attribute
> table but I’m not sure.
>
>
>
> Thanks,
>
>
>
> *Paul Wittle *
>
> <https://www.dorsetcouncil.gov.uk/>
>
> *Business Solutions Analyst (GIS)*
>
> *ICT Operations *
>
> *Dorset Council*
>
> 01305 228473
> <01305%20228473%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20>
>
> dorsetcouncil.gov.uk <https://www.dorsetcouncil.gov.uk>
>
>
>
> <https://www.facebook.com/DorsetCouncilUK>
>
> <https://instagram.com/DorsetCouncilUK>
>
> <https://twitter.com/DorsetCouncilUK>
>
>
> This e-mail and any files transmitted with it are intended solely for the
> use of the individual or entity to whom they are addressed. It may contain
> unclassified but sensitive or protectively marked material and should be
> handled accordingly. Unless you are the named addressee (or authorised to
> receive it for the addressee) you may not copy or use it, or disclose it to
> anyone else. If you have received this transmission in error please notify
> the sender immediately. All traffic may be subject to recording and/or
> monitoring in accordance with relevant legislation. Any views expressed in
> this message are those of the individual sender, except where the sender
> specifies and with authority, states them to be the views of Dorset
> Council. Dorset Council does not accept service of documents by fax or
> other electronic means. Virus checking: Whilst all reasonable steps have
> been taken to ensure that this electronic communication and its attachments
> whether encoded, encrypted or otherwise supplied are free from computer
> viruses, Dorset Council accepts no liability in respect of any loss, cost,
> damage or expense suffered as a result of accessing this message or any of
> its attachments. For information on how Dorset Council processes your
> information, please see www.dorsetcouncil.gov.uk/416433
> _______________________________________________
> Qgis-user mailing list
> Qgis-user at lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20200703/05a9b4d2/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image003.png
Type: image/png
Size: 4476 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20200703/05a9b4d2/attachment.png>


More information about the Qgis-user mailing list