• Post Reply Bookmark Topic Watch Topic
  • New Topic

GUI Design Solution  RSS feed

 
Steve Dyke
Ranch Hand
Posts: 1779
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Not sure which forum this should go in.

I have a remote table with 50,000 plus records. On my user iterface form I have an option to lookup record by document number. There is also a link that will display list of document numbers the user can choose from. What would be a good way to display the choices without all 50,000 records at once but have access to them. This is probably a function that will get used very little.
 
Henrique Ordine
Ranch Hand
Posts: 129
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A good way to not display all records is to use a filter in your SQL statement.
For example, where document.type = "doc".
 
Steve Dyke
Ranch Hand
Posts: 1779
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I wish it was that easy. However, the document field is the only column I am retreiving for this list. I have seen some sites that only pull up a certian number of records with a way to navigate thru the rest. How could this be done?
 
Rob Spoor
Sheriff
Posts: 21117
85
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm doubting a bit between JDBC and Swing, but I'm more inclined towards JDBC.

Edit: and now towards Swing with that latest update
[ October 15, 2008: Message edited by: Rob Prime ]
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Steve Dyke:
I wish it was that easy. However, the document field is the only column I am retreiving for this list. I have seen some sites that only pull up a certian number of records with a way to navigate thru the rest. How could this be done?


Still sounds like JDBC/SQL question to me. Depending on your Database vendor you can do something like this:

select [column(s)] from [table] [start, limit]

so, assuming you want to bring everything back from a table called Documents and rows 15 - 25...

select * from documents limit 15, 10
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
BTW, this is called "paging" data. That should help your search when you need to determine how to implement such a feature in a UI.
 
Rob Spoor
Sheriff
Posts: 21117
85
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Gregg Bolinger:


Still sounds like JDBC/SQL question to me. Depending on your Database vendor you can do something like this:

select [column(s)] from [table] [start, limit]

so, assuming you want to bring everything back from a table called Documents and rows 15 - 25...

select * from documents limit 15, 10

Please note that this form of paging is not uniform. This way, with LIMIT, is MySQL. MS SQL Server has TOP, and Oracle is quite difficult with regards to this form of paging.
 
Brian Cole
Author
Ranch Hand
Posts: 954
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Steve Dyke:
Not sure which forum this should go in.


This isn't a bad forum for this post, but it could have used a more descriptive title.

I have a remote table with 50,000 plus records. On my user iterface form I have an option to lookup record by document number. There is also a link that will display list of document numbers the user can choose from. What would be a good way to display the choices without all 50,000 records at once but have access to them. This is probably a function that will get used very little.


You may want to take a look at this older thread on this topic from last year.
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!