--- title: "system.db.clearQueryCache" description: "Clears the cache for a Named Query in a project." --- # system.db.clearQueryCache > Clears the cache for a Named Query in a project. This function is used in **Python Scripting**. ## Description This clears the caches for specified Named Queries in a project, or all Named Queries if no arguments are provided. ## Client Permission Restrictions This scripting function has no [Client Permission](ignition-modules\vision\vision-project-properties\vision-project-properties.md#vision-permissions-properties) restrictions. ## Syntax `system.db.clearQueryCache(project, path)` ### Parameters Type | Parameter | Description ------- | ------- | ----- String | `project` | The project that contains the named query whose cache needs to be cleared. An error will be thrown if no local project is found. String | `path` | The path to the named query whose cache needs to be cleared. ### Returns Nothing ### Scope Gateway, Vision Client, Perspective Session ## Code Examples ```python title="Clear a Named Query Cache within a Project" projectName = "myProject" namedQueryPath = "folder/selectFromInventory" system.db.clearQueryCache(projectName, namedQueryPath) ``` ```python title="Clear All Named Query Caches" # Clear all of the Named Query caches from the default project. # Note that this includes caches generated from elsewhere on the Gateway. system.db.clearQueryCache() ```