Yeah those are possible. Not 100% sure with point 2 but the others can be done. QGIS uses || for concatenation too.<br><br><div class="gmail_quote">On Thu, Jul 28, 2011 at 7:45 PM, kimaidou <span dir="ltr"><<a href="mailto:kimaidou@gmail.com">kimaidou@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Hi<br><br>Since I have not tested your patch yet, it is hard to comment. The functionnalities I am thinking of for labelling purpose are :<br>
* be able to add uppercase to the first letters of words<br>* add a line break after the first space after X letters (such as Mapserver does with WRAP and MAXLENGTH ( <a href="http://mapserver.org/mapfile/label.html" target="_blank">http://mapserver.org/mapfile/label.html</a> )<br>
* Concatenate one or more columns with expresssions, such as : colA || '(' || colB || ')' (here I am using the postgresql || syntaxe )<br><font color="#888888"><br>kimaidou</font><div><div></div><div class="h5">
<br><br><br><div class="gmail_quote">2011/7/28 Nathan Woodrow <span dir="ltr"><<a href="mailto:madmanwoo@gmail.com" target="_blank">madmanwoo@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">+1 from me too. A virtual column would be a very handy feature however you must be able to add one to read only datasets eg MI Tab otherwise their is no real advantage. The expression labelling I'm working on works with read only datasets. I think the expression based labelling and the virtual column thing could exist together quite well the former being a short cut in the labeling gui for the latter.<div>
<br></div><div>Check out <a href="http://hub.qgis.org/issues/3488" target="_blank">http://hub.qgis.org/issues/3488</a> and <a href="https://github.com/NathanW2/Quantum-GIS/tree/expression-labels" target="_blank">https://github.com/NathanW2/Quantum-GIS/tree/expression-labels</a><span style="color:rgb(48, 48, 48);font-family:Verdana, Tahoma, Arial, sans-serif;font-size:11px"> </span>for the status of my patch. I have been away for a couple of weeks but I will be getting back into over the next couple of weeks.</div>
<div><br></div><div>Anyone else got any other thoughts?</div><div><br></div><font color="#888888"><div>- Nathan</div></font><div><div></div><div><div><br><div><div><div><div><div class="gmail_quote">On Thu, Jul 28, 2011 at 6:49 PM, kimaidou <span dir="ltr"><<a href="mailto:kimaidou@gmail.com" target="_blank">kimaidou@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br><br>+1 for Mayeul Nathan. This "virtual column" would be a very handy tool ! E.G for labelling<br><font color="#888888"><br>
kimaidou</font><div><div></div><div><br><br><div class="gmail_quote">2011/7/28 Andreas Neumann <span dir="ltr"><<a href="mailto:a.neumann@carto.net" target="_blank">a.neumann@carto.net</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Nathan,<br>
<br>
Good to hear that you are working on this.<br>
<br>
I just wonder if it wouldn't make sense to have a general purpose "virtual column" that could be introduced in QGIS. This would be useful for:<br>
<br>
* labeling<br>
* map tips/QGIS server tooltip display<br>
* symbology<br>
* plugins<br>
* others?<br>
<br>
It would be convenient to use the field calculator, but instead of just writing out to a physically existing column it would create a new virtual column, just like a virtual column in a database view.<br>
<br>
Otherwise one would have to develop the same functionality several times - for labeling, for tooltips, etc.<br>
<br>
Do you think it would be feasible to implement this on a lower level in QGIS so that users could transparently work with virtual columns wherever they want?<br>
<br>
Andreas<br>
<br>
On Thu, 28 Jul 2011 16:09:56 +1000, Nathan Woodrow wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
My upcoming patch that adds expression based labels will be able<br>
to achieve this once it's completed; I'm just cleaning up the UI<br>
and testing everything then I will get the guys to merge it in.<br>
Until then you will need to create a new column.<br>
<br>
- Nathan<br>
<br>
On Wed, Jul 27, 2011 at 9:15 PM, Torsten Lange wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Ok, thank you, Andreas!<br>
<br>
Torsten<br>
<br>
Am Mittwoch 27 Juli 2011, 11:00:01 schrieb Andreas Neumann:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi,<br>
</blockquote>
><br>
> Currently, you have to create a new column. I usually create a<br>
view in<br>
> Postgis for this purpose.<br>
><br>
> It is in on the wishlist that one can create a "virtual" column<br>
- not<br>
> only for labeling, but also for map tips and perhaps<br>
symbolization.<br>
> Until then you have to do it yourself.<br>
><br>
> Andreas<br>
><br>
> On Tue, 26 Jul 2011 22:51:34 +0200, Torsten Lange wrote:<br>
> > Hi,<br>
> ><br>
> > Is there a way just to print - lets say - the first four<br>
letters of a<br>
> > objects<br>
> > name? Or must I create a new row for that?<br>
> ><br>
> > Thank you, Torsten<br>
> > ______________________________<u></u>_________________<br>
> > Qgis-user mailing list<br>
> > <a href="mailto:Qgis-user@lists.osgeo.org" target="_blank">Qgis-user@lists.osgeo.org</a> [1]<br>
> > <a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">http://lists.osgeo.org/<u></u>mailman/listinfo/qgis-user</a> [2]<br>
<br>
______________________________<u></u>_________________<br>
Qgis-user mailing list<br>
<a href="mailto:Qgis-user@lists.osgeo.org" target="_blank">Qgis-user@lists.osgeo.org</a> [3]<br>
<a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">http://lists.osgeo.org/<u></u>mailman/listinfo/qgis-user</a> [4]<br>
</blockquote>
<br>
<br>
<br>
Links:<br>
------<br>
[1] mailto:<a href="mailto:Qgis-user@lists.osgeo.org" target="_blank">Qgis-user@lists.osgeo.<u></u>org</a><br>
[2] <a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">http://lists.osgeo.org/<u></u>mailman/listinfo/qgis-user</a><br>
[3] mailto:<a href="mailto:Qgis-user@lists.osgeo.org" target="_blank">Qgis-user@lists.osgeo.<u></u>org</a><br>
[4] <a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">http://lists.osgeo.org/<u></u>mailman/listinfo/qgis-user</a><br>
[5] mailto:<a href="mailto:tlange@gwdg.de" target="_blank">tlange@gwdg.de</a><br>
</blockquote>
<br>
-- <br>
--<br><font color="#888888">
Andreas Neumann<br>
Böschacherstrasse 10A<br>
8624 Grüt (Gossau ZH)<br>
Switzerland<br>
______________________________<u></u>_________________<br>
Qgis-developer mailing list<br>
<a href="mailto:Qgis-developer@lists.osgeo.org" target="_blank">Qgis-developer@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/qgis-developer" target="_blank">http://lists.osgeo.org/<u></u>mailman/listinfo/qgis-<u></u>developer</a><br>
</font></blockquote></div><br>
</div></div><br>_______________________________________________<br>
Qgis-developer mailing list<br>
<a href="mailto:Qgis-developer@lists.osgeo.org" target="_blank">Qgis-developer@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/qgis-developer" target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a><br>
<br></blockquote></div><br></div></div></div></div></div>
</div></div></blockquote></div><br>
</div></div></blockquote></div><br>