ryansuitposungkono / openjs-grid

Automatically exported from code.google.com/p/openjs-grid
0 stars 0 forks source link

Grid fails on display if there is more than 1 primary key (i.e. clustered key/lookup table) #2

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Point grid at a table with multiple primary keys.

What is the expected output? What do you see instead?
Great question: One could wave this away as "working as intended."  The code 
itself assumes that getPrimaryKey() will only return 1 result; it takes the 
very first answer.

What version of the product are you using? On what operating system?
1.3, Mac Server PHP 5.2; client: MacBook Pro (Safari/FF), Snow Leopard.

Please provide any additional information below.

Original issue reported on code.google.com by vep....@gmail.com on 11 Mar 2011 at 6:47

GoogleCodeExporter commented 9 years ago

Original comment by Seancla...@gmail.com on 4 Apr 2011 at 5:27

GoogleCodeExporter commented 9 years ago
Thanks for looking into this.  It's really an interesting issue because I am 
attempting to use Grid to edit "Lookup Tables" relating one main table with 
another, and ideally these AREN'T represented by primary keys because that 
would allow for data like:

1  OptionA  OptionB
2  OptionA OptionB
3 OptionA OptionB

when the intent is that OptionA + OptionB represent a unique choice in the 
lookup table.  I'm able to work around it by kind of just telling folks to pay 
attention, but as this lookup table grows large, I need to have referential 
integrity.

Original comment by vep....@gmail.com on 8 Apr 2011 at 4:29