构建一个服务器客户端应用程序,客户端从服务器获取数据,该服务器存储在本地C ++服务器上

问题描述:

构建一个服务器 - 客户端应用程序,其中客户端从服务器获取数据,存储在服务器本地C ++上。



服务器从数据库获取数据并在本地存储,客户通过连接它来使用该数据。



数据是关于各种客户ID区分的各种客户。

有十万客户。



主要目的是根据客户ID快速搜索和获取数据。



需要建议我们应该使用哪种数据结构在本地存储数据,这应该按照排序的方式存储或者不排序,以及我们必须使用哪种搜索技术。





非常感谢您提出的所有建议。



我尝试了什么:



考虑将数据存储在BST中以便快速检索,因为快速搜索和撤销是主要目标。

Building a Server-Client application where client gets data from server, that stored on server locally C++.

Server is fetching data from a database and storing it locally, and client is using that data by connecting to it.

Data is about various clients differentiated by various client id's.
There are lakhs of clients.

"Main aim is to search and fetch data very fast on basis of client id."

Need suggestions on which data structure we should use to store data locally, and this should be stored in sorted manner or unsorted and which searching technique we must use.


Many thanks for all your suggestions.

What I have tried:

Thinking to store data in BST for fast retrieval as fast searching and retreaving is main aim.

如果您有数据库你读过你有一个存储,支持各种方法,如提取,过滤和排序。



因此,不需要创建另一个存储数据存储数据的存储。当存储不同步时,它也可能导致不必要的副作用。



对于性能优化,使用存储过程从数据库中检索数据。性能还取决于您的数据库设计。所以使用正确的设计是必不可少的。
If you have a database you already have a storage that supports various methods like fetching, filtering, and sorting.

So there should be no need to create another storage holding data stored also in the database. It might also lead to unwanted side effects when the storages are out of sync.

For performance optimisation used stored procedures to retrieve data from the database. The performance depends also on your database design. So using a proper design is essential.


是的,我们有数据库。

但每天数据库上有数百万次点击。



因此,为了让它更快,我想在本地存储一些数据。
Yes, we have database.
but there are millions of hits on database daily.

So,to make it more fast was thinking to store some data locally.


使用信息检索技术部署搜索引擎可能是更好的方法。 br />
数据可以压缩并本地存储
deploy a search engine maybe a better way, using information retrieval technology.
data can be compressed and store locally