[DiscordArchive] what alternative would you suggest for pulling in data from the database?
[DiscordArchive] what alternative would you suggest for pulling in data from the database?
Archived author: Anchy • Posted: 2022-07-13T10:08:04.605000+00:00
Original source
what alternative would you suggest for pulling in data from the database?
Archived author: Anchy • Posted: 2022-07-13T10:08:22.921000+00:00
Original source
i could map the table to a class or something maybe and read that?
Archived author: Honey • Posted: 2022-07-13T10:11:12.180000+00:00
Original source
I think it's best practice to use the Data already read into the core, or If more Data is required, use a container.
Archived author: Nyeriah • Posted: 2022-07-13T10:12:32.818000+00:00
Original source
can't give you alternatives without further information about what you're trying to achieve, but essentially what honey said
Archived author: Anchy • Posted: 2022-07-13T10:14:44.318000+00:00
Original source
i have a table with one column being item ids and the other column being a mask of what classes can receive said item, the code will then check the db mask with the classmask and reward the player with that item if they are included in the mask
Archived author: Honey • Posted: 2022-07-13T10:16:20.582000+00:00
Original source
Assuming you dont have more than 10k items with only ID and classmask in that list, I'd recommend a container.
Archived author: Anchy • Posted: 2022-07-13T10:17:04.510000+00:00
Original source
there's only 42 rows but it will definitely expand in the future
Archived author: Anchy • Posted: 2022-07-13T10:17:17.473000+00:00
Original source
what container are you referring to?
Archived author: Anchy • Posted: 2022-07-13T10:17:24.893000+00:00
Original source
i am a beginner with c++
Archived author: Honey • Posted: 2022-07-13T10:18:02.410000+00:00
Original source
Container means, load it at startup, reading the whole table and then assign the values to a variable/Array/table