Announcement

Collapse
No announcement yet.

Transpose field contents to field labels

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Transpose field contents to field labels

    If I have a result with the following in three separate rows from a database:

    PriceGroup: 0
    Price: 1.20

    PriceGroup: 1
    Price: 2.30

    PriceGroup: 2
    Price: 3.00

    Is it possible to transpose these such that I could create a grid to display something as follows:

    Price Group 0 Price Group 1 Price Group 2
    ========== ========== ==========
    1.20 2.30 3.00


    Any help would be appreciated!

  • #2
    As long as the fields do not need to be updated you can consider using an event to fill a label containing the <table> instructions and display the label?
    Albert Drent
    aducom software netherlands
    scriptcase partner, reseller, support and (turn-key) development
    www.scriptcase.eu / www.scriptcase.nl

    Comment


    • #3
      If you are using MySQL you really should have a look at the GROUP_CONCAT() function.

      jsb

      Comment

      Working...
      X