How to solve my Column.Render problem.

How to solve my Column.Render problem.

trevctrevc Posts: 1Questions: 1Answers: 0

Hi All,

Really do appreciate any help with this,

I have the following DataTable showing this table;

My problem is I have 4 columns in total which I need to be rendered from external tables.

For example, all my LocationID, StatusID, BadgeTypeID and PrinteSiteID are values, but I would like to render them to show their String values in said tables as opposed to the direct value.

The StatusID, BadgeType ID and PrinteSiteID are small tables with <10 entries.

However, my LocationID will be >200.

I'm just curious if anyone has done anything similar and if they could even nudge me in the right direction.

Thanks again,

Trev,

Answers

  • kthorngrenkthorngren Posts: 21,167Questions: 26Answers: 4,921

    One option is to create your SQL query to use a join to fetch the appropriate Status, for example, for each row.

    Another option is to use separate ajax requests, maybe getJSON, to fetch the data from each of the tables then store them in Javascript objects with the key being the StatusID. Then in the render function you can can just return the value from the Javascript object variable.

    Kevin

This discussion has been closed.