Hi
I want to start a program that can store lots of information. Example a long client list with names, phone, address, email, age. I see there is a data stack option but i do not see the limit it can handle. I've read SQL database you can go thousands of entries if I'm correct but which type would be the best option? As i do not see any information on the SQL there are lots of stacks help around.
Alternatively you can define a class ClientList with private data members such as names, phone, etc and declare a STL container such as vector holding ClientList objects. You can then check the vector's max_size() method to see if it fits your needs and can even use reserve() to set aside memory according to your requirements if you have some idea how many class objects there'd be eventually. Using a STL container has the advantage of being able to use the container methods, general STL algorithms, iterators, functors/lambdas etc
A stack is limited only by the size of the heap on your system. The maximum size of the heap depends on your operating system and available memory.
The more important decision you have to make is if and how you want to persist the information in your program. A stack does not persist on disk unless you write code to read and write the stack to/from a disk file. The choice between persisting data to a simple text file and a SQL data base usually depends on whether you have related tables of information. If you have related tables of information, SQL is far superior to writing your own tables to disk. If you're implementing a simple phonebook even with thousands of entries, persisting to/from a text file is usually sufficient.
thanks so to start learning myself I'll start with the text file and then go for an updated heavy program with lots more entries and the SQL with it. It seems that it is completely 2 different ways of handling data and connecting to the data. and everything needs to be understood.