Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
嗨,我有一个数据库,每分钟都会向其中添加新数据。我在 winform 中有一个 C# 数据网格,它显示了这个 db 表。我们每 5 分钟刷新一次这个数据网格。有没有办法只显示新添加的数据而不显示旧数据
timestamp您可以通过在数据库中添加来完成此操作。
timestamp
通过这种方式,您可以设置时间戳的限制,您将不得不查询数据库以仅update在您的grid.
update
grid
如果需要限制 in 中的数据,也可以设置limitin 查询gridview。
limit
gridview
您可以在ASP.net以及winforms.
ASP.net
winforms
您可以通过descending使用新生成的 uniqueId 过滤记录来执行此操作,并获得具有一定限制的特定数据(1 -10 限制可以由您定义)。
descending