Highest id
Highest id
Soshiro
Posts: 2Questions: 1Answers: 0
Im looking for the highest id in the datatable regardless of whether its on this page or the next.
Im a student and new to all of this, so i apologise for my vagueness.
This discussion has been closed.
Answers
I should elaborate a bit. I want to look for the highest id in the table so i can var++ and then create a new page.
we use datatable as a index for exercise we've made and its all javascript.
Sounds like you want to use
rows().data()
to get the data for the rows and then simply loop over it. You could usepluck()
if you want to get a specific data point out of the data and the perform your loop on it, or do something more clever such as sorting to get the maximum value.Allan