<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">Hi Andreas<br>
      On 2014/11/08 18:34, Andreas Neumann wrote:<br>
    </div>
    <blockquote cite="mid:545E4607.9070806@carto.net" type="cite">
      <meta content="text/html; charset=ISO-8859-1"
        http-equiv="Content-Type">
      Hi Zoltan,<br>
      <br>
      There are many other file formats besides shapes, including many
      databases. So people should stop thinking that the universe only
      circles around shapefiles.<br>
    </blockquote>
    Yes. I know. That's exactly what I am banging my head about.<br>
    Do you know that some 15 years back, I had to spend vast amounts of
    energy explaining to some of my clients that SHP file format does
    NOT support topology!! <br>
    But I supposed I have been spoilt. <br>
    In 1984 when I started Geograph, I had a Mainframe (you know what
    that is? :-)  ) based GIS package (called SICAD) and in 1984 I could
    write scripts, crawl up and down the data structure and do almost
    anything because it had a fully topologically connected spatial data
    structure.<br>
    I ditched that in 1989 in favour of Unix based Genamap (now Linux)
    [and gone bung, but the SW still works], also FULL topology and full
    script-ability, and I still use that unless my clients demand that I
    use their software (and then they provide the licensing for the
    project).<br>
    So, I have mostly by-passed the rigorous requirements of conformity.<br>
    <blockquote cite="mid:545E4607.9070806@carto.net" type="cite"> <br>
      With these other file formats it is not very common to ship other
      files along with the main file.<br>
    </blockquote>
    Ha ha ha... tell that to the masses.<br>
    Guess what format our friendly RSA mapping office gives out their
    Vector Data in?<br>
    <blockquote cite="mid:545E4607.9070806@carto.net" type="cite"> <br>
      Why do you think that drag/drop or "add layer" is unintuitive.
      Those are the normal ways to load a layer in QGIS.<br>
    </blockquote>
    Well, not so much the 'drag & drop', but the way Layer
    Definition Files are loaded:  <br>
    Because I never thought of it as an option (yes, that's my failure),
    but also because intuitively it should be on the "Add Layer" button
    or list, and not as a separate item slightly further down.<br>
    If it appeared on the addlayer button, it would be noticed, and
    people would be more likely to check what that option does (and
    learn). It is in fact just another way to load a "map type".<br>
    So, I'm not at all grumbling, just suggesting that maybe that way of
    loading a layer should be on the Add Layer button/dropdown. (and not
    separately on the layer dropdown list)<br>
    <br>
    Anyway, thanks for your input,<br>
    Regards,<br>
    Zoltan<br>
    <blockquote cite="mid:545E4607.9070806@carto.net" type="cite"> <br>
      Andreas<br>
      <br>
      <br>
      <div class="moz-cite-prefix">On 07.11.2014 18:49, Zoltan Szecsei
        wrote:<br>
      </div>
      <blockquote cite="mid:545D063D.5000007@geograph.co.za" type="cite">
        <meta content="text/html; charset=ISO-8859-1"
          http-equiv="Content-Type">
        <div class="moz-cite-prefix">On 2014/11/07 19:19, Zoltan Szecsei
          wrote:<br>
        </div>
        <blockquote cite="mid:545CFF17.2080103@geograph.co.za"
          type="cite">
          <meta content="text/html; charset=ISO-8859-1"
            http-equiv="Content-Type">
          <div class="moz-cite-prefix">Thanks for the pointer to 'Save
            Layer Definition file' - I've never noticed that, so I'll
            play with that for a bit.<br>
            <br>
            <br>
            On 2014/11/07 18:59, Andreas Neumann wrote:<br>
          </div>
          <blockquote cite="mid:545CFA6B.3040907@carto.net" type="cite">
            <meta content="text/html; charset=ISO-8859-1"
              http-equiv="Content-Type">
            <br>
            However, if you save a layer definition file along with the
            shapefile and re-add that, they are preserved. So you can
            just store the layer definition file along with the shape
            and you are fine to share the data with your colleagues,
            preserving virtual fields ;-)<br>
          </blockquote>
        </blockquote>
        Hi,<br>
        OK - not very intuitive, (to have to either drag and drop the
        qlr file into the layer panel, or to "add layer from definition
        file")<br>
        <br>
        Any reason that QGIS can't be made to look for qlr files when
        opening the SHP file "the normal way"?<br>
        <br>
        Regards & thanks for the help.<br>
        Zoltan<br>
        <br>
        <blockquote cite="mid:545CFF17.2080103@geograph.co.za"
          type="cite">
          <blockquote cite="mid:545CFA6B.3040907@carto.net" type="cite">
            <br>
            Andreas<br>
            <br>
            <div class="moz-cite-prefix">On 07.11.2014 17:32, Zoltan
              Szecsei wrote:<br>
            </div>
            <blockquote cite="mid:545CF41A.1040704@geograph.co.za"
              type="cite">
              <meta content="text/html; charset=ISO-8859-1"
                http-equiv="Content-Type">
              <div class="moz-cite-prefix">Hi Andreas,<br>
                I'll fiddle with the Postgis idea - thanks.<br>
                The orange part below:<br>
                I closed the shapefile, deleted from legend and
                re-opened it - but could not see my virtual field, nor
                the expression I used to create it.<br>
                Have I missed a trick somewhere?<br>
                <br>
                Regards,<br>
                Z<br>
                <br>
                On 2014/11/07 18:25, Andreas Neumann wrote:<br>
              </div>
              <blockquote cite="mid:545CF265.1040604@carto.net"
                type="cite">
                <meta content="text/html; charset=ISO-8859-1"
                  http-equiv="Content-Type">
                Hi,<br>
                <br>
                What you probably ask for are database triggers combined
                with storage. This is not what virtual fields are for.
                If they were stored - they wouldn't be called virtual
                ;-)<br>
                <br>
                You can do that f.e. with Postgis. With shapefiles not.
                <font color="#ff6600">However, if you share the project
                  with the other PC, the virtual fields work fine</font>.<br>
                <br>
                Andreas<br>
                <br>
                <div class="moz-cite-prefix">On 07.11.2014 17:21, Zoltan
                  Szecsei wrote:<br>
                </div>
                <blockquote cite="mid:545CF16F.20604@geograph.co.za"
                  type="cite">
                  <meta content="text/html; charset=ISO-8859-1"
                    http-equiv="Content-Type">
                  <div class="moz-cite-prefix">Hi Matthias,<br>
                    Thanks for the quick answer.<br>
                    The virtual field acts just like I want it to,
                    except that it does not permanently store the column
                    in the attribute table.<br>
                    I tried getting clever by then adding a second
                    'Field Calculation' to update the existing 'Sheet'
                    field from the virtual field, but that won't do it
                    either.<br>
                    <br>
                    So, for me there are two shortcomings:<br>
                    <ol>
                      <li>To be able to store and recall the
                        'Expression' and not lose it after closing the
                        Field Calculator</li>
                      <li>To be able to add the virtual fields that you
                        create, into the attribute table.</li>
                      <li>(And then of course to re-open the Shape file
                        on another PC and have these Field Calculations
                        still functional)<br>
                      </li>
                    </ol>
                    Any further possibilities I can try?<br>
                    <br>
                    Regards & thanks again,<br>
                    Zoltan<br>
                    <br>
                    <br>
                    On 2014/11/07 18:01, Matthias Kuhn wrote:<br>
                  </div>
                  <blockquote cite="mid:545CECD7.9030808@gmx.ch"
                    type="cite">
                    <pre wrap="">Hi Zoltan,

Since QGIS 2.6 this possibility exists. It is called "Virtual Field".
You must not create the attribute when creating the shapefile. Just open
the field calculator, create a new field in there and check the "virtual
field" checkbox.

Regards,
Matthias

On 07.11.2014 16:54, Zoltan Szecsei wrote:
</pre>
                    <blockquote type="cite">
                      <pre wrap="">Hi,
I'm using QGIS 2.6.0 on Win 7 x64 - installed via OSGEO4w

Is there a way to store your field calculator expression to always
process and update that specific field, should geometry be edited or
created for that Layer?

Let's say I want to create a blank POINT shape file, with a text
attribute called "Sheet".
Whenever a POINT is created or moved, I want this field to be
dynamically updated with:

     tostring(abs(toint($y)))+tostring(abs(toint($x)))

For testing thus far have:

  * created 2 points
  * Opened the field calculator, clicked 'Update Existing Field' and
    put in the expression.
  * The two existing points now have the correct TEXT values in the
    Sheet field
  * I close the Field calculator
  * Create a new point in my layer
  * open the attribute table to find that the 'Sheet' field for this
    new point is blank
  * I open the Field Calculator and I cannot even find a way to call
    back the previous expression I used.


Am I using the correct QGIS functionality to achieve what I need to,
and if so, where am I going wrong?

Thanks & regards,
Zoltan


-- 

===========================================
Zoltan Szecsei PrGISc [PGP0031]
Geograph (Pty) Ltd.
GIS and Photogrammetric Services

P.O. Box 7, Muizenberg 7950, South Africa.

Mobile: +27-83-6004028
Fax:    +27-86-6115323     <a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="http://www.geograph.co.za">www.geograph.co.za</a>
===========================================


_______________________________________________
Qgis-developer mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:Qgis-developer@lists.osgeo.org">Qgis-developer@lists.osgeo.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/qgis-developer">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a>
</pre>
                    </blockquote>
                  </blockquote>
                  <br>
                  <br>
                  <pre class="moz-signature" cols="72">-- 

===========================================
Zoltan Szecsei PrGISc [PGP0031]
Geograph (Pty) Ltd.
GIS and Photogrammetric Services

P.O. Box 7, Muizenberg 7950, South Africa.

Mobile: +27-83-6004028
Fax:    +27-86-6115323     <a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="http://www.geograph.co.za">www.geograph.co.za</a>
===========================================</pre>
                  <br>
                  <fieldset class="mimeAttachmentHeader"></fieldset>
                  <br>
                  <pre wrap="">_______________________________________________
Qgis-developer mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:Qgis-developer@lists.osgeo.org">Qgis-developer@lists.osgeo.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/qgis-developer">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a></pre>
                </blockquote>
                <br>
                <br>
                <fieldset class="mimeAttachmentHeader"></fieldset>
                <br>
                <pre wrap="">_______________________________________________
Qgis-developer mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:Qgis-developer@lists.osgeo.org">Qgis-developer@lists.osgeo.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/qgis-developer">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a></pre>
              </blockquote>
              <br>
              <br>
              <pre class="moz-signature" cols="72">-- 

===========================================
Zoltan Szecsei PrGISc [PGP0031]
Geograph (Pty) Ltd.
GIS and Photogrammetric Services

P.O. Box 7, Muizenberg 7950, South Africa.

Mobile: +27-83-6004028
Fax:    +27-86-6115323     <a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="http://www.geograph.co.za">www.geograph.co.za</a>
===========================================</pre>
              <br>
              <fieldset class="mimeAttachmentHeader"></fieldset>
              <br>
              <pre wrap="">_______________________________________________
Qgis-developer mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:Qgis-developer@lists.osgeo.org">Qgis-developer@lists.osgeo.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/qgis-developer">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a></pre>
            </blockquote>
            <br>
            <br>
            <fieldset class="mimeAttachmentHeader"></fieldset>
            <br>
            <pre wrap="">_______________________________________________
Qgis-developer mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:Qgis-developer@lists.osgeo.org">Qgis-developer@lists.osgeo.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/qgis-developer">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a></pre>
          </blockquote>
          <br>
          <br>
          <pre class="moz-signature" cols="72">-- 

===========================================
Zoltan Szecsei PrGISc [PGP0031]
Geograph (Pty) Ltd.
GIS and Photogrammetric Services

P.O. Box 7, Muizenberg 7950, South Africa.

Mobile: +27-83-6004028
Fax:    +27-86-6115323     <a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="http://www.geograph.co.za">www.geograph.co.za</a>
===========================================</pre>
          <br>
          <fieldset class="mimeAttachmentHeader"></fieldset>
          <br>
          <pre wrap="">_______________________________________________
Qgis-developer mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:Qgis-developer@lists.osgeo.org">Qgis-developer@lists.osgeo.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/qgis-developer">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a></pre>
        </blockquote>
        <br>
        <br>
        <pre class="moz-signature" cols="72">-- 

===========================================
Zoltan Szecsei PrGISc [PGP0031]
Geograph (Pty) Ltd.
GIS and Photogrammetric Services

P.O. Box 7, Muizenberg 7950, South Africa.

Mobile: +27-83-6004028
Fax:    +27-86-6115323     <a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="http://www.geograph.co.za">www.geograph.co.za</a>
===========================================</pre>
        <br>
        <fieldset class="mimeAttachmentHeader"></fieldset>
        <br>
        <pre wrap="">_______________________________________________
Qgis-developer mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:Qgis-developer@lists.osgeo.org">Qgis-developer@lists.osgeo.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/qgis-developer">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a></pre>
      </blockquote>
      <br>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
Qgis-developer mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Qgis-developer@lists.osgeo.org">Qgis-developer@lists.osgeo.org</a>
<a class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/qgis-developer">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a></pre>
    </blockquote>
    <br>
    <br>
    <pre class="moz-signature" cols="72">-- 

===========================================
Zoltan Szecsei PrGISc [PGP0031]
Geograph (Pty) Ltd.
GIS and Photogrammetric Services

P.O. Box 7, Muizenberg 7950, South Africa.

Mobile: +27-83-6004028
Fax:    +27-86-6115323     <a class="moz-txt-link-abbreviated" href="http://www.geograph.co.za">www.geograph.co.za</a>
===========================================</pre>
  </body>
</html>