Due to the popularity of network applications, such as multimedia, online shopping, Internet of Things (IoT), and 5G, the contents cached in the routers are frequently replaced in Content-Centric Networking (CCN). Generally, cache miss causes numerous propagated packets to get the required content that deteriorates network congestion and delay the response time of consumers. Many caching strategies and routing policies were proposed to solve the problem. This paper presents an alternative solution by designing a query-based routing table update mechanism to increase the accuracy of routing tables. By adding an additional query content in interest packets, our approach real-time explores the cached content in routers and updated the routing table accordingly. This paper uses a general network simulator, ndnSIM, to compare basic CCN and our approach. The results show that our approach improves the response time of consumers and network congestion and is compatible with general forwarding strategies.