• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Cannot view data in pop-up window in ascending order

 
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi there,

I was looking for some help or advise on the following.
Any help is much appreciated.

I am trying to correct the sequencing of a pop-up window corrected so that they appear in the right sequence.
10 should come after 9, in fact the single digit Code should appear as 01 thru 09. Any help/advise is much appreciated

To display some data in a pop-up window in ascending order the SQL created
in a javascript. The SQL is named "SUPER".

The SQL retrieves the data as sorted in ascending order when run/unit-tested independently in the database.

However, the data is NOT seen in sorted ASCENDING order in the pop-up window on the client side.

The SQL is as follows -



Please note that the a.table_code is of char type and the data it returns is ranging from 1 - 10.
In order for the data to be displayed in ascending order on the client-side pop-up window, I modified the SQL as follows



This also independently returns me data in ascending order when run unit-tested in the database.

However as above, both these SQL's do not return the data in ascending order on the client-side when seen in the new pop-up window.

The code for the JSP that actually runs/invokes the SQL is as follows -


The code for the new pop-up window is as follows -


The JSP code used to display the pop-up is -



Any help or advise is much appreciated.

Thanks in advance!

Cheers,
Jyotsna Pai
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
(This isn't an app that anyone besides like developers can use, right?! Like not for the public?)
 
Jyotsna Pai
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, it is not for public.

Thanks and Regards,
Jyotsna Pai
 
Jyotsna Pai
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello everyone,

Thanks to anyone who views the page.
I resolved the issue myself, by changing the code for the JSP that actually runs/invokes the SQL.
I used the Collections.sort() method, using a Comparator to sort Strings that held integers/numbers.

The code for the JSP that actually runs/invokes the SQL is as follows -


Rest all other code remains unchanged.

Thanks.

Best Regards,
Jyotsna Pai
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I don't even know where to begin, but glad you got it working. For your sake, I hope it never stops working, because tracking down problems in that code will be a nightmare.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic