1

I have a Geoserver layer, which contains numbers on a million scale in one of the attributes.

If I query these features, I get back a number in this format: 4.1E7 instead of this: 410000000

Is there a workaround or setting for this?

I use PostgreSQL 9.3 as a backend, and it is a Geoserver 2.4.2.

1

You can change the getFeatureInfo template used by geoserver, see section "Advanced Formatting". You could try to intercept the ${attribute.rawValue} and print this directly or modify it before sending the feature info back.

| improve this answer | |
  • Thank you @tareq, it totally solved my issue! And BTW, can I use all freemarker "Buildt-in"-s in my template to format my rawValue? freemarker.org/docs/dgui_quickstart_template.html#autoid_7 – Benedek Simo Apr 20 '16 at 6:47
  • I am not too familiar with the templating in geoserver. You could try, which fits best for you and post here, what you did. – ulrich Apr 20 '16 at 10:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.