{"id":39655,"date":"2026-03-23T11:40:42","date_gmt":"2026-03-23T11:40:42","guid":{"rendered":"https:\/\/crocoblock.com\/knowledge-base\/?post_type=article&#038;p=39655"},"modified":"2026-03-23T11:40:45","modified_gmt":"2026-03-23T11:40:45","slug":"macros-for-query-builder","status":"publish","type":"article","link":"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/","title":{"rendered":"Macros for Query Builder"},"content":{"rendered":"\n<p>Macros are the core of a dynamic website. <a href=\"https:\/\/crocoblock.com\/plugins\/jetengine\/\" target=\"_blank\" rel=\"noreferrer noopener\"><em>JetEngine<\/em><\/a> provides macros for its different modules \u2013 <strong>Forms<\/strong>, <a href=\"https:\/\/crocoblock.com\/knowledge-base\/features\/relations-overview\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Relations<\/strong><\/a>, <a href=\"https:\/\/crocoblock.com\/knowledge-base\/features\/dynamic-visibility-overview\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Dynamic Visibility<\/strong><\/a>, etc. You can learn more about each of them in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/articles\/jetengine-macros-guide\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Macros Guide<\/strong><\/a>.\u00a0<\/p>\n\n\n\n<p>In this tutorial, we will look at the macros used in <a href=\"https:\/\/crocoblock.com\/knowledge-base\/features\/query-builder-overview\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Query Builder<\/strong><\/a> and cover the most common use cases.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"macros-basics\">Macros Basics<\/h2>\n\n\n\n<div class=\"wp-block-group is-layout-constrained wp-block-group-is-layout-constrained\"><div class=\"wp-block-group__inner-container\">\n<p>A macro is a part of a string that gets replaced with a certain value depending on the purpose of the macro. In other words, a macro is a variable that can return different values based on the context. For example, the %current_id% macro returns the ID of the current object. On the single page of a post, the %current_id% macro returns the ID of that post.<\/p>\n\n\n\n<p>Assume our goal is to display the current post in the query results. Since we need to query posts, we create a \u201c<a href=\"https:\/\/crocoblock.com\/knowledge-base\/articles\/jetengine-query-builder-posts-query-type\/\" target=\"_blank\" rel=\"noreferrer noopener\">Posts Query<\/a>.\u201d The <strong>Post In <\/strong>field in the <strong>Post &amp; Page<\/strong> query settings tab expects a post ID.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/post-in-field-in-the-posts-query.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/post-in-field-in-the-posts-query.webp\" alt=\"post in field in the posts query\" class=\"wp-image-51296\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/post-in-field-in-the-posts-query.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/post-in-field-in-the-posts-query-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/post-in-field-in-the-posts-query-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/post-in-field-in-the-posts-query-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/post-in-field-in-the-posts-query-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/post-in-field-in-the-posts-query-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>Therefore, if we use the %current_id% macro in the <strong>Post In<\/strong> field and preview the results from a certain post, we will see that post in the query results.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder.webp\" alt=\"using the current id macro in the query builder\" class=\"wp-image-51299\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>In our example, we preview the results for a post titled \u201cLight Show,\u201d which has the \u201c316\u201d ID. If we wanted to include that particular post in the query results, we could manually enter its ID.<\/p>\n\n\n\n<div class=\"wp-block-image size-large is-resized\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/including-post-in-posts-query.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/including-post-in-posts-query.webp\" alt=\"including post in posts query\" class=\"wp-image-51294\" style=\"width:840px;height:auto\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/including-post-in-posts-query.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/including-post-in-posts-query-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/including-post-in-posts-query-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/including-post-in-posts-query-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/including-post-in-posts-query-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/including-post-in-posts-query-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>However, the dynamic solution that includes the \u201cCurrent ID\u201d macro allows us to avoid creating numerous duplicate queries for different posts manually.<\/p>\n\n\n\n<p>Similarly, you can use the \u201cCurrent ID\u201d<strong> <\/strong>macro in other custom query fields that support post IDs.&nbsp;<\/p>\n\n\n\n<p>Note that not all macros return a single ID. Some macros return a list of IDs separated by commas \u2014 for example, the \u201cCurrent Terms\u201d<strong> <\/strong>macro returns the list of current post terms\u2019 IDs (e.g., \u20182234, 2342, 4958\u2019). Other macros will return values of a different kind.<\/p>\n<\/div><\/div>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"creating-a-custom-query-in-query-builder\">Creating a Custom Query in Query Builder<\/h2>\n\n\n\n<div class=\"wp-block-group is-layout-constrained wp-block-group-is-layout-constrained\"><div class=\"wp-block-group__inner-container\">\n<p>To use macros of <strong>Query Builder<\/strong>, start by creating a custom query in <strong><em>WordPress Dashboard &gt; JetEngine &gt; Query Builder &gt; Add New<\/em><\/strong>.&nbsp;<\/p>\n\n\n\n<p>There are different types of queries: \u201cPosts Query,\u201d \u201cTerms Query,\u201d \u201cUsers Query\u201d, \u201cComments Query,\u201d etc. The choice of a custom query depends on the items that will be queried. For example, a \u201cPosts Query\u201d<strong> <\/strong>should be chosen to query a list of posts. If users should be queried, select the \u201c<a href=\"https:\/\/crocoblock.com\/knowledge-base\/articles\/jetengine-query-builder-users-query-type\/\" target=\"_blank\" rel=\"noreferrer noopener\">Users Query<\/a>\u201d type. The query type also determines which objects are returned in the query results (the \u201cPosts Query\u201d<strong> <\/strong>returns a list of posts, the \u201cUsers Query\u201d<strong> <\/strong>returns a list of users, etc.).<\/p>\n\n\n\n<p>Each field in the query settings includes a description that specifies the value to be inserted in that field. Most fields support macros, but ensure to use macros according to their purpose and according to the value that the macro returns (check the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#macros-basics\"><strong>Macros Basics<\/strong><\/a> chapter for more information).<\/p>\n\n\n<div class=\"note-banner d-flex border-bold border-jetsmartfilters rounded overflow-hidden p-20\"><div class=\"mr-12\"><svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\"><path d=\"M1 21H23L12 2L1 21ZM13 18H11V16H13V18ZM13 14H11V10H13V14Z\" fill=\"#FA5450\"\/><\/svg><\/div><div class=\"d-flex flex-column\"><div class=\"text-900 mb-12\">Warning<\/div><p class=\"m-0\">The fields in the <strong>Query Builder<\/strong> do not support manually entered macros. So, instead of typing %current_id% in the field manually, select the \u201cCurrent ID\u201d macro from the list of available macros that appear after pressing the \u201c<strong>database<\/strong>\u201d icon near the required field.<\/p><\/div><\/div>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/list-of-query-builder-macros.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1823\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/list-of-query-builder-macros.webp\" alt=\"list of query builder macros\" class=\"wp-image-51295\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/list-of-query-builder-macros.webp 1823w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/list-of-query-builder-macros-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/list-of-query-builder-macros-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/list-of-query-builder-macros-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/list-of-query-builder-macros-1536x927.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/list-of-query-builder-macros-600x362.webp 600w\" sizes=\"(max-width: 1823px) 100vw, 1823px\" \/><\/a><\/div>\n<\/div><\/div>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"applying-macros-in-different-use-cases\">Applying Macros in Different Use Cases<\/h2>\n\n\n\n<div class=\"wp-block-group is-layout-constrained wp-block-group-is-layout-constrained\"><div class=\"wp-block-group__inner-container\">\n<p>Below, we will cover the most popular cases where macros of <strong>Query Builder <\/strong>are utilized.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"limiting-query-results-to-the-current-post-or-excluding-the-current-post-from-query-results\">Limiting query results to the current post or excluding the current post from query results<\/h3>\n\n\n\n<p>The current post ID can be retrieved using the \u201cCurrent ID\u201d<strong> <\/strong>macro. Use it to show only the current post in a widget\/block\/element that supports custom <em>JetEngine<\/em> queries (e.g., in a <a href=\"https:\/\/crocoblock.com\/knowledge-base\/articles\/jetengine-maps-listing-overview\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Map Listing<\/strong><\/a>).\u00a0Create a \u201cPosts Query\u201d<strong>. <\/strong>In the <strong>General <\/strong>tab, specify the <strong>Post Type<\/strong>.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/specify-post-type-in-the-settings-of-the-posts-query.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1823\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/specify-post-type-in-the-settings-of-the-posts-query.webp\" alt=\"specify post type in the settings of the posts query\" class=\"wp-image-51297\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/specify-post-type-in-the-settings-of-the-posts-query.webp 1823w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/specify-post-type-in-the-settings-of-the-posts-query-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/specify-post-type-in-the-settings-of-the-posts-query-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/specify-post-type-in-the-settings-of-the-posts-query-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/specify-post-type-in-the-settings-of-the-posts-query-1536x927.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/specify-post-type-in-the-settings-of-the-posts-query-600x362.webp 600w\" sizes=\"(max-width: 1823px) 100vw, 1823px\" \/><\/a><\/div>\n\n\n\n<p>Then, proceed to the <strong>Post &amp; Page <\/strong>tab of settings and insert the \u201cCurrent ID\u201d<strong> <\/strong>macro into the <strong>Post In <\/strong>field.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder.webp\" alt=\"using the current id macro in the query builder\" class=\"wp-image-51299\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-the-current-id-macro-in-the-query-builder-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>If you need to exclude the current post from the query results, place the \u201cCurrent ID\u201d<strong> <\/strong>macro into the <strong>Post Not In <\/strong>field instead of the <strong>Post In<\/strong> field.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-query-results.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-query-results.webp\" alt=\"exclude the current post from the query results\" class=\"wp-image-51302\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-query-results.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-query-results-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-query-results-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-query-results-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-query-results-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-query-results-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>After saving the query, create a <a href=\"https:\/\/crocoblock.com\/knowledge-base\/articles\/jetengine-what-is-a-listing-template\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Listing Template<\/strong><\/a> for the same post type and display the listing on the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetthemecore\/how-to-add-a-single-post-page-template-with-elementor\/\" target=\"_blank\" rel=\"noreferrer noopener\">Single Post page<\/a> using the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/features\/listing-grid-widget-overview\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Listing Grid<\/strong><\/a><strong>. <\/strong>Apply the created query on the <strong>Listing Grid <\/strong>as described in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#applying-the-created-query\"><strong>Applying the Created Query<\/strong><\/a> step.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"display-posts-on-the-taxonomy-archive-page\">Display posts on the taxonomy archive page<\/h3>\n\n\n\n<p>To query posts by the current term, use the \u201cQueried term\u201d<strong> <\/strong>macro. The macro returns the ID of the current term and can be used in the <strong>Tax Query <\/strong>tab of a <strong>Posts Query<\/strong> to display posts on the taxonomy archive pages.&nbsp;<\/p>\n\n\n\n<p>Create a \u201cPosts Query.\u201d<strong> <\/strong>In the <strong>General <\/strong>tab, specify the <strong>Post Type<\/strong>.<\/p>\n\n\n\n<p>Then, proceed to the <strong>Tax Query <\/strong>tab of settings and press the \u201c<strong>Add new<\/strong>\u201d button to add a tax query clause.<\/p>\n\n\n\n<p>In the added repeater item set such options:<\/p>\n\n\n\n<ul>\n<li>Select the needed <strong>Taxonomy<\/strong>;<\/li>\n\n\n\n<li>In the <strong>Field<\/strong> dropdown, select the \u201cTerm ID\u201d option because we are comparing the ID of the current term to the IDs of terms in the taxonomy;<\/li>\n\n\n\n<li>In the <strong>Terms<\/strong> field, select the \u201cQueried term\u201d macro \u2014 it retrieves the ID of the current term;<\/li>\n\n\n\n<li>Select the \u201cIN\u201d <strong>Compare operator<\/strong>.&nbsp;<\/li>\n<\/ul>\n\n\n\n<p>Then, save the query.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/showing-posts-on-the-taxonomy-archive-page.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1823\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/showing-posts-on-the-taxonomy-archive-page.webp\" alt=\"showing posts on the taxonomy archive page\" class=\"wp-image-51306\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/showing-posts-on-the-taxonomy-archive-page.webp 1823w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/showing-posts-on-the-taxonomy-archive-page-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/showing-posts-on-the-taxonomy-archive-page-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/showing-posts-on-the-taxonomy-archive-page-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/showing-posts-on-the-taxonomy-archive-page-1536x927.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/showing-posts-on-the-taxonomy-archive-page-600x362.webp 600w\" sizes=\"(max-width: 1823px) 100vw, 1823px\" \/><\/a><\/div>\n\n\n\n<p>This custom query serves as a replacement for the<strong> Use as Archive Template <\/strong>toggle in the <strong>Listing Grid <\/strong>widget\/block\/element settings.<\/p>\n\n\n\n<figure class=\"wp-block-image text-center size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"301\" height=\"565\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/use-as-archive-template-toggle-in-listing-grid.webp\" alt=\"use as archive template toggle in listing grid\" class=\"wp-image-51307\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/use-as-archive-template-toggle-in-listing-grid.webp 301w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/use-as-archive-template-toggle-in-listing-grid-160x300.webp 160w\" sizes=\"(max-width: 301px) 100vw, 301px\" \/><\/figure>\n\n\n\n<p>It also provides a way to separate posts on the taxonomy archive page by post type \u2014 just create a new query for each new post type that should be displayed separately. Apply the created query on the <strong>Listing Grid <\/strong>as described in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#applying-the-created-query\"><strong>Applying the Created Query<\/strong><\/a> step.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"display-posts-related-by-terms-on-the-single-post-page\">Display posts related by terms on the single post page<\/h3>\n\n\n\n<p>To display posts that are connected with the terms of the current post, use the \u201cCurrent terms\u201d<strong> <\/strong>macro. The macro returns a list of term IDs connected to the current post. It can be used in the <strong>Tax Query <\/strong>tab of a <strong>Posts Query<\/strong> to display posts related to the same terms as the current post.<\/p>\n\n\n\n<p>Create a \u201cPosts Query.\u201d<strong> <\/strong>In the <strong>General <\/strong>tab, specify the <strong>Post Type<\/strong>.<\/p>\n\n\n\n<p>Then, proceed to the <strong>Tax Query <\/strong>tab of settings and press the \u201c<strong>Add new<\/strong>\u201d button to add a tax query clause.<\/p>\n\n\n\n<p>In the added repeater item set such options:<\/p>\n\n\n\n<ul>\n<li>Select the needed <strong>Taxonomy<\/strong>;<\/li>\n\n\n\n<li>In the <strong>Field<\/strong> dropdown, select the \u201cTerm ID\u201d option because we are comparing the IDs listed in the <strong>Terms<\/strong> field to the IDs of terms in the taxonomy;<\/li>\n\n\n\n<li>In the <strong>Terms<\/strong> field, select the \u201cCurrent terms\u201d macro. In its settings, select the same <strong>Taxonomy<\/strong> as in the first field;<\/li>\n\n\n\n<li>Select the \u201cIN\u201d <strong>Compare operator<\/strong>.<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/show-posts-with-the-same-terms-with-the-help-of-query-builder.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1823\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/show-posts-with-the-same-terms-with-the-help-of-query-builder.webp\" alt=\"show posts with the same terms with the help of query builder\" class=\"wp-image-51305\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/show-posts-with-the-same-terms-with-the-help-of-query-builder.webp 1823w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/show-posts-with-the-same-terms-with-the-help-of-query-builder-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/show-posts-with-the-same-terms-with-the-help-of-query-builder-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/show-posts-with-the-same-terms-with-the-help-of-query-builder-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/show-posts-with-the-same-terms-with-the-help-of-query-builder-1536x927.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/show-posts-with-the-same-terms-with-the-help-of-query-builder-600x362.webp 600w\" sizes=\"(max-width: 1823px) 100vw, 1823px\" \/><\/a><\/div>\n\n\n\n<p>To exclude the current post from the query results, go to the <strong><em>Post &amp; Page &gt; Post Not In <\/em><\/strong>field and place the \u201cCurrent ID\u201d<strong> <\/strong>macro.<\/p>\n\n\n\n<p>Then, save the query.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-posts-related-by-terms.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-posts-related-by-terms.webp\" alt=\"exclude the current post from the posts related by terms\" class=\"wp-image-51301\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-posts-related-by-terms.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-posts-related-by-terms-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-posts-related-by-terms-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-posts-related-by-terms-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-posts-related-by-terms-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/exclude-the-current-post-from-the-posts-related-by-terms-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>After saving the query, create a <strong>Listing Template<\/strong> for the same post type, and display the listing on the single post page using the <strong>Listing Grid. <\/strong>Apply the created query on the <strong>Listing Grid <\/strong>as described in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#applying-the-created-query\">Applying the Created Query<\/a> step.<\/p>\n\n\n\n<p>Additionally, you can check <a href=\"https:\/\/www.youtube.com\/watch?v=7Cc8YCn5y-8\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>How to Display Related Posts in WordPress Using Listing Grid<\/strong><\/a>.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"display-posts-on-the-search-results-archive-page\">Display posts on the search results archive page<\/h3>\n\n\n\n<p>The \u201cQuery Variable\u201d macro can be used to display posts on the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetthemecore\/how-to-create-an-archive-template-to-display-the-search-results\/\" target=\"_blank\" rel=\"noreferrer noopener\">Search Results<\/a> page.\u00a0<\/p>\n\n\n\n<p>Create a \u201cPosts Query.\u201d<strong> <\/strong>In the <strong>General <\/strong>tab, specify the <strong>Post Type<\/strong>.<\/p>\n\n\n\n<p>Then, select the \u201cQuery Variable\u201d<strong> <\/strong>macro for the <strong>Search Keyword <\/strong>field and specify the <strong>Variable Name<\/strong> \u2014 \u2018s\u2019.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-query-variable-macro-to-display-search-results.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-query-variable-macro-to-display-search-results.webp\" alt=\"using query variable macro to display search results\" class=\"wp-image-51308\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-query-variable-macro-to-display-search-results.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-query-variable-macro-to-display-search-results-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-query-variable-macro-to-display-search-results-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-query-variable-macro-to-display-search-results-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-query-variable-macro-to-display-search-results-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-query-variable-macro-to-display-search-results-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>If someone uses the search function to search for \u201clight\u201d, the query will return posts of the specified post type that have a match in title, content, or excerpt. Apply this query to the <strong>Listing Grid <\/strong>widget\/block\/element on the Search Results archive template to make the listing adjust to the searched keyword.<\/p>\n\n\n\n<p>This custom query also supports the <strong>Ajax Search <\/strong>of the <a href=\"https:\/\/crocoblock.com\/plugins\/jetsearch\/\" target=\"_blank\" rel=\"noreferrer noopener\"><em>JetSearch<\/em><\/a><strong> <\/strong>plugin.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"display-posts-with-the-same-meta-value-as-the-current-post\">Display posts with the same meta value as the current post<\/h3>\n\n\n\n<p>Use the \u201cCurrent meta value\u201d<strong> <\/strong>macro to display posts that have the same value in a certain <a href=\"https:\/\/crocoblock.com\/knowledge-base\/features\/meta-field-types-overview\/\" target=\"_blank\" rel=\"noreferrer noopener\">meta field<\/a> as the current post.<\/p>\n\n\n\n<p>Assuming there is a \u201c<a href=\"https:\/\/crocoblock.com\/knowledge-base\/features\/meta-field-types-overview\/#radio\" target=\"_blank\" rel=\"noreferrer noopener\">Radio<\/a>\u201d<strong> <\/strong>meta field called \u201cHot deals\u201d in a \u201cProperties\u201d <a href=\"https:\/\/crocoblock.com\/knowledge-base\/features\/custom-post-type-overview\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>CPT<\/strong><\/a>. It has two options \u2014 \u201cyes\u201d and \u201cno.\u201d On a single property post page, we want to display other properties that have the same option selected in the \u201cHot deals\u201d meta field. For example, the \u201cRainforest Guest House\u201d post has the option \u201cyes\u201d selected.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/property-post-with-a-radio-meta-field-selected.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/property-post-with-a-radio-meta-field-selected.webp\" alt=\"property post with a radio meta field selected\" class=\"wp-image-51304\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/property-post-with-a-radio-meta-field-selected.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/property-post-with-a-radio-meta-field-selected-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/property-post-with-a-radio-meta-field-selected-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/property-post-with-a-radio-meta-field-selected-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/property-post-with-a-radio-meta-field-selected-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/property-post-with-a-radio-meta-field-selected-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>The goal is to display other properties where the \u201cyes\u201d option was selected and to exclude the current post from the query results.&nbsp;<\/p>\n\n\n\n<p>Create a \u201cPosts Query.\u201d<strong> <\/strong>In the <strong>General <\/strong>tab, specify the <strong>Post Type<\/strong> (here, \u201cProperties\u201d).<\/p>\n\n\n\n<p>Then, proceed to the <strong>Meta Query <\/strong>tab of the settings and add a new meta clause.<\/p>\n\n\n\n<p>In the added repeater item set such options:<\/p>\n\n\n\n<ul>\n<li>For the <strong>Field key\/name<\/strong> field, press the \u201c<strong>database<\/strong>\u201d icon and select the \u201cJetEngine meta field\u201d<strong> <\/strong>macro. In the pop-up, select the needed meta <strong>Field<\/strong> and \u201cField name\/key\/ID\u201d in the <strong>Return<\/strong> dropdown. Press the \u201c<strong>Apply<\/strong>\u201d button;<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/jetengine-meta-field-macro-in-query-builder.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"618\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/jetengine-meta-field-macro-in-query-builder-1024x618.webp\" alt=\"jetengine meta field macro in query builder\" class=\"wp-image-51303\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/jetengine-meta-field-macro-in-query-builder-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/jetengine-meta-field-macro-in-query-builder-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/jetengine-meta-field-macro-in-query-builder-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/jetengine-meta-field-macro-in-query-builder-1536x927.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/jetengine-meta-field-macro-in-query-builder-600x362.webp 600w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/jetengine-meta-field-macro-in-query-builder.webp 1823w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/div>\n\n\n\n<ul>\n<li>For the <strong>Compare<\/strong> field, select \u201cEqual (=)\u201d;<\/li>\n\n\n\n<li>For the <strong>Value <\/strong>field, press the \u201c<strong>database<\/strong>\u201d icon and select the \u201cCurrent meta value\u201d<strong> <\/strong>macro. In the pop-up, specify the <strong>Meta field<\/strong> key. The meta key can be copied from the <strong>Name\/ID<\/strong> field of the meta field settings. Then, press the \u201c<strong>Apply<\/strong>\u201d button.<\/li>\n<\/ul>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/current-meta-field-macro-in-query-builder.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1823\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/current-meta-field-macro-in-query-builder.webp\" alt=\"current meta field macro in query builder\" class=\"wp-image-51300\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/current-meta-field-macro-in-query-builder.webp 1823w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/current-meta-field-macro-in-query-builder-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/current-meta-field-macro-in-query-builder-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/current-meta-field-macro-in-query-builder-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/current-meta-field-macro-in-query-builder-1536x927.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/current-meta-field-macro-in-query-builder-600x362.webp 600w\" sizes=\"(max-width: 1823px) 100vw, 1823px\" \/><\/a><\/div>\n\n\n\n<p>The \u201cCurrent meta value\u201d macro returns the value of the specified meta field of the current post. Then, using the settings of the meta clause, it is compared to values in the same meta fields of other posts. As a result, the custom query returns all posts where the meta value equals the current post\u2019s meta value.&nbsp;<\/p>\n\n\n\n<p>To exclude the current post from the query results, go to the <strong><em>Post &amp; Page &gt; Post Not In <\/em><\/strong>field and place the \u201cCurrent ID\u201d<strong> <\/strong>macro.<\/p>\n\n\n\n<p>After saving the query, create a <strong>Listing Template<\/strong> for the same post type, and display the listing on the single post page using the <strong>Listing Grid. <\/strong>Apply the created query on the <strong>Listing Grid <\/strong>as described in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#applying-the-created-query\"><strong>Applying the Created Query<\/strong><\/a> step.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"query-posts-by-the-posts-meta-field\">Query posts by the \u201cPosts\u201d meta field<\/h3>\n\n\n\n<p>Using the \u201cCurrent meta value as string\u201d<strong> <\/strong>macro, it is possible to display posts selected in the \u201c<a href=\"https:\/\/crocoblock.com\/knowledge-base\/features\/meta-field-types-overview\/#posts\" target=\"_blank\" rel=\"noreferrer noopener\">Posts<\/a>\u201d<strong> <\/strong>meta field of the current post.<\/p>\n\n\n\n<p>If the <strong>Multiple <\/strong>setting is enabled for the \u201cPosts\u201d<strong> <\/strong>meta field, the meta field value is saved as an array. The \u201cCurrent meta value as string\u201d<strong> <\/strong>macro converts the value to a string and allows it to be used in the <strong>Query Builder<\/strong>.<\/p>\n\n\n\n<div class=\"wp-block-image size-large is-resized\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/posts-meta-field-of-jetengine.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/posts-meta-field-of-jetengine.webp\" alt=\"posts meta field of jetengine\" class=\"wp-image-51309\" style=\"width:841px;height:auto\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/posts-meta-field-of-jetengine.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/posts-meta-field-of-jetengine-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/posts-meta-field-of-jetengine-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/posts-meta-field-of-jetengine-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/posts-meta-field-of-jetengine-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/posts-meta-field-of-jetengine-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>Create a \u201cPosts Query.\u201d In the <strong>General <\/strong>tab, you can specify the same <strong>Post Type<\/strong> that was selected in the \u201cPosts\u201d<strong> <\/strong>meta field\u2019s settings.<\/p>\n\n\n\n<p>Next, proceed to the <strong>Post &amp; Page <\/strong>tab, press the \u201c<strong>database<\/strong>\u201d icon for the <strong>Post In <\/strong>field, and select the \u201cCurrent meta value as string macro.\u201d In the pop-up, specify the <strong>Meta field<\/strong> key. The meta key can be copied from the <strong>Name\/ID<\/strong> field of the meta field settings. Then, press the \u201c<strong>Apply<\/strong>\u201d button and save the query.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-meta-value-as-string-macro-in-the-post-in-field-of-posts-query.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1823\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-meta-value-as-string-macro-in-the-post-in-field-of-posts-query.webp\" alt=\"using current meta value as string macro in the post in field of posts query\" class=\"wp-image-51311\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-meta-value-as-string-macro-in-the-post-in-field-of-posts-query.webp 1823w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-meta-value-as-string-macro-in-the-post-in-field-of-posts-query-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-meta-value-as-string-macro-in-the-post-in-field-of-posts-query-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-meta-value-as-string-macro-in-the-post-in-field-of-posts-query-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-meta-value-as-string-macro-in-the-post-in-field-of-posts-query-1536x927.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-meta-value-as-string-macro-in-the-post-in-field-of-posts-query-600x362.webp 600w\" sizes=\"(max-width: 1823px) 100vw, 1823px\" \/><\/a><\/div>\n\n\n\n<p>After saving the query, create a <strong>Listing Template<\/strong><strong> <\/strong>for the post type that was selected in the settings of the \u201cPosts\u201d<strong> <\/strong>meta field, and display the listing on a single post page with the help of the <strong>Listing Grid. <\/strong>Apply the created query on the <strong>Listing Grid <\/strong>as described in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#applying-the-created-query\"><strong>Applying the Created Query<\/strong><\/a> step.&nbsp;<\/p>\n\n\n\n<p>This way, the posts selected in the \u201cPosts\u201d<strong> <\/strong>meta field of the current post can be displayed as a listing on the front end.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"display-authored-posts-on-the-account-page-of-a-user\">Display authored posts on the Account page of a user<\/h3>\n\n\n\n<p>Using the \u201cCurrent user ID\u201d<strong> <\/strong>macro, you can retrieve posts created by the currently logged-in user.&nbsp;<\/p>\n\n\n\n<p>Create a \u201cPosts Query.\u201d In the <strong>General <\/strong>tab, you can specify the <strong>Post Type<\/strong> in which posts should be retrieved.<\/p>\n\n\n\n<p>Then, proceed to the <strong>Author <\/strong>tab of the custom query settings. For the <strong>Author ID<\/strong> field, set the \u201cCurrent user ID\u201d<strong> <\/strong>macro.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-user-id-macro-to-retrieve-posts-of-the-current-author.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1823\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-user-id-macro-to-retrieve-posts-of-the-current-author.webp\" alt=\"using current user id macro to retrieve posts of the current author\" class=\"wp-image-51312\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-user-id-macro-to-retrieve-posts-of-the-current-author.webp 1823w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-user-id-macro-to-retrieve-posts-of-the-current-author-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-user-id-macro-to-retrieve-posts-of-the-current-author-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-user-id-macro-to-retrieve-posts-of-the-current-author-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-user-id-macro-to-retrieve-posts-of-the-current-author-1536x927.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-user-id-macro-to-retrieve-posts-of-the-current-author-600x362.webp 600w\" sizes=\"(max-width: 1823px) 100vw, 1823px\" \/><\/a><\/div>\n\n\n\n<p>The \u201cCurrent User ID\u201d<strong> <\/strong>macro returns the ID of the currently logged-in user. Therefore, this custom query can be used to display authored posts on the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/creating-user-account-page\/\">Account<\/a> page.&nbsp;<\/p>\n\n\n\n<p>To use the query on the Account page, firstly, create a <strong>Listing Template<\/strong> for the same post type; then, place the <strong>Listing Grid <\/strong>widget\/block\/element on the Account page, select the <strong>Listing<\/strong>, and apply the query as described in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#applying-the-created-query\"><strong>Applying the Created Query<\/strong><\/a> step.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"display-authored-posts-on-the-public-profile-page\">Display authored posts on the Public Profile Page<\/h3>\n\n\n\n<p>The \u201cQueried user ID\u201d<strong> <\/strong>macro retrieves the ID of the user on one\u2019s <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/how-to-set-up-public-single-user-page\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Public Profile Page<\/strong><\/a><strong> <\/strong>created in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/articles\/jetengine-user-profile-builder-overview\/\"><strong>Profile Builder<\/strong><\/a><strong> <\/strong>module of <em>JetEngine<\/em>. Use it to display posts authored by the queried user.\u00a0<\/p>\n\n\n\n<p>Create a \u201cPosts Query.\u201d<strong> <\/strong>In the <strong>General <\/strong>tab, you can specify the <strong>Post Type<\/strong> in which posts should be retrieved.<\/p>\n\n\n\n<p>Then, proceed to the <strong>Author <\/strong>tab of the custom query settings. For the <strong>Author ID<\/strong> field, set the \u201cQueried user ID\u201d<strong> <\/strong>macro.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-queried-user-id-macro-to-retrieve-posts-of-the-queried-author.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1823\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-queried-user-id-macro-to-retrieve-posts-of-the-queried-author.webp\" alt=\"using queried user id macro to retrieve posts of the queried author\" class=\"wp-image-51316\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-queried-user-id-macro-to-retrieve-posts-of-the-queried-author.webp 1823w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-queried-user-id-macro-to-retrieve-posts-of-the-queried-author-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-queried-user-id-macro-to-retrieve-posts-of-the-queried-author-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-queried-user-id-macro-to-retrieve-posts-of-the-queried-author-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-queried-user-id-macro-to-retrieve-posts-of-the-queried-author-1536x927.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-queried-user-id-macro-to-retrieve-posts-of-the-queried-author-600x362.webp 600w\" sizes=\"(max-width: 1823px) 100vw, 1823px\" \/><\/a><\/div>\n\n\n\n<p>To use the query on the Public Profile Page, firstly, create a <strong>Listing Template<\/strong> for the same post type; then, place the <strong>Listing Grid <\/strong>widget\/block\/element on a template belonging to the Public Profile Page, select the <strong>Listing<\/strong>, and apply the query as described in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#applying-the-created-query\"><strong>Applying the Created Query<\/strong><\/a> step.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"display-the-author-of-the-current-post\">Display the author of the current post<\/h3>\n\n\n\n<p>Create a \u201c<a href=\"https:\/\/crocoblock.com\/knowledge-base\/articles\/jetengine-query-builder-users-query-type\/\" target=\"_blank\" rel=\"noreferrer noopener\">Users Query<\/a>.\u201d In the <strong><em>Include\/Exclude > Include<\/em><\/strong> field, set the \u201cPost Author ID\u201d<strong> <\/strong>macro.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-post-author-id-macro-to-retrieve-current-post-author.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-post-author-id-macro-to-retrieve-current-post-author.webp\" alt=\"using post author id macro to retrieve current post author\" class=\"wp-image-51315\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-post-author-id-macro-to-retrieve-current-post-author.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-post-author-id-macro-to-retrieve-current-post-author-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-post-author-id-macro-to-retrieve-current-post-author-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-post-author-id-macro-to-retrieve-current-post-author-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-post-author-id-macro-to-retrieve-current-post-author-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-post-author-id-macro-to-retrieve-current-post-author-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>When placed on a single page of a post, the query will return the user who is the post&#8217;s author. To use the query, firstly, create a<strong> <\/strong><a href=\"https:\/\/crocoblock.com\/knowledge-base\/articles\/jetengine-how-to-create-a-listing-template-for-users\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Listing Template<\/strong> for users<\/a>, place the <strong>Listing Grid <\/strong>widget\/block\/element on the single post page or template, select the created <strong>Listing<\/strong>, and apply the query as described in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#applying-the-created-query\"><strong>Applying the Created Query<\/strong><\/a><strong> <\/strong>step.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"display-terms-associated-with-the-current-post\">Display terms associated with the current post<\/h3>\n\n\n\n<p>The \u201cCurrent ID\u201d<strong> <\/strong>macro can be used in a \u201cTerms Query\u201d<strong> <\/strong>to retrieve terms connected to the current post or product.\u00a0<\/p>\n\n\n\n<p>Create a \u201c<a href=\"https:\/\/crocoblock.com\/knowledge-base\/articles\/jetengine-query-builder-terms-query-type\/\" target=\"_blank\" rel=\"noreferrer noopener\">Terms Query<\/a>.\u201d In the <strong>General <\/strong>tab of settings, specify the needed <strong>Taxonomy<\/strong>. In the <strong>Object\/Post IDs<\/strong> field below, set the <strong>Current ID <\/strong>macro to fetch the ID of the current post automatically.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-id-macro-in-terms-query-to-get-terms-of-current-post.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-id-macro-in-terms-query-to-get-terms-of-current-post.webp\" alt=\"using current id macro in terms query to get terms of current post\" class=\"wp-image-51310\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-id-macro-in-terms-query-to-get-terms-of-current-post.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-id-macro-in-terms-query-to-get-terms-of-current-post-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-id-macro-in-terms-query-to-get-terms-of-current-post-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-id-macro-in-terms-query-to-get-terms-of-current-post-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-id-macro-in-terms-query-to-get-terms-of-current-post-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-current-id-macro-in-terms-query-to-get-terms-of-current-post-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>To use this query, <a href=\"https:\/\/crocoblock.com\/knowledge-base\/articles\/creating-a-listing-template-for-the-terms-from-custom-taxonomy-with-jetengine\/\" target=\"_blank\" rel=\"noreferrer noopener\">create a <strong>Listing Template<\/strong> for the same taxonomy<\/a>, place the <strong>Listing Grid <\/strong>widget\/block\/element on the single post page or template, select the created <strong>Listing<\/strong>, and apply the query as described in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#applying-the-created-query\"><strong>Applying the Created Query<\/strong><\/a> step.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"display-posts-added-by-the-current-user-to-the-data-store\">Display posts added by the current user to the Data Store<\/h3>\n\n\n\n<p>The \u201cGet Store\u201d<strong> <\/strong>macro allows retrieving the IDs of objects added by the currently logged-in user to the specified <a href=\"https:\/\/crocoblock.com\/plugins\/jetengine\/data-store\/\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Data Store<\/strong><\/a>. Use this method to show posts that the current user has liked or visited, depending on the <strong>Data Store <\/strong>settings.<\/p>\n\n\n\n<p>Create a \u201cPosts Query.\u201d In the <strong>General <\/strong>tab, you can specify the <strong>Post Type<\/strong>.<\/p>\n\n\n\n<p>Then, go to the <strong><em>Post &amp; Page > Post In<\/em> <\/strong>field and set the \u201cGet Store\u201d<strong> <\/strong>macro. In the pop-up, select the required <strong>Store<\/strong>.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-store-macro-to-show-posts-liked-by-current-user.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1823\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-store-macro-to-show-posts-liked-by-current-user.webp\" alt=\"using get store macro to show posts liked by current user\" class=\"wp-image-51313\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-store-macro-to-show-posts-liked-by-current-user.webp 1823w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-store-macro-to-show-posts-liked-by-current-user-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-store-macro-to-show-posts-liked-by-current-user-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-store-macro-to-show-posts-liked-by-current-user-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-store-macro-to-show-posts-liked-by-current-user-1536x927.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-store-macro-to-show-posts-liked-by-current-user-600x362.webp 600w\" sizes=\"(max-width: 1823px) 100vw, 1823px\" \/><\/a><\/div>\n\n\n\n<p>After saving the query, create a <strong>Listing Template<\/strong> for the same custom post type; place the <strong>Listing Grid <\/strong>widget\/block\/element on the page where the posts added to the <strong>Data Store <\/strong>should be visible; select the created listing template and apply the query as described in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#applying-the-created-query\"><strong>Applying the Created Query<\/strong><\/a> step.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"display-users-who-liked-the-current-post\">Display users who liked the current post<\/h3>\n\n\n\n<p>The \u201cGet users from store item\u201d<strong> <\/strong>retrieves the user IDs who added the specified item to the <strong>Data Store<\/strong>. One use case is to display users who liked the current post.\u00a0<\/p>\n\n\n\n<p>Create a \u201cUsers Query.\u201d Go to the <strong><em>Include\/Exclude > Include<\/em><\/strong> field that expects the user IDs and set the \u201cGet users from store item\u201d<strong> <\/strong>macro for this field. In the pop-up, select the needed <strong>Data Store <\/strong>and specify the <strong>Context<\/strong> \u2014 \u201cPost.\u201d<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-users-from-store-item-macro-to-display-users-who-liked-the-current-post.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1823\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-users-from-store-item-macro-to-display-users-who-liked-the-current-post.webp\" alt=\"using get users from store item macro to display users who liked the current post\" class=\"wp-image-51314\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-users-from-store-item-macro-to-display-users-who-liked-the-current-post.webp 1823w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-users-from-store-item-macro-to-display-users-who-liked-the-current-post-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-users-from-store-item-macro-to-display-users-who-liked-the-current-post-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-users-from-store-item-macro-to-display-users-who-liked-the-current-post-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-users-from-store-item-macro-to-display-users-who-liked-the-current-post-1536x927.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/using-get-users-from-store-item-macro-to-display-users-who-liked-the-current-post-600x362.webp 600w\" sizes=\"(max-width: 1823px) 100vw, 1823px\" \/><\/a><\/div>\n\n\n\n<p>When placed on a single post page, the query retrieves the users who added the post to the <strong>Data Store<\/strong>. To use the query, create a<strong> <\/strong><strong>Listing Template<\/strong> for users, place the <strong>Listing Grid <\/strong>widget\/block\/element on the single post page, select the created <strong>Listing<\/strong>, and apply the query as described in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#applying-the-created-query\"><strong>Applying the Created Query<\/strong><\/a> step.<\/p>\n<\/div><\/div>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"using-macros-fallbacks\">Using Macros Fallbacks<\/h2>\n\n\n\n<div class=\"wp-block-group is-layout-constrained wp-block-group-is-layout-constrained\"><div class=\"wp-block-group__inner-container\">\n<p>In most cases, the custom query will return every single item, even when a macro was applied incorrectly, a context wasn\u2019t specified, or nothing was found for the current selection. To make the query return zero results when nothing is found, apply a fallback value to the macro.&nbsp;<\/p>\n\n\n\n<p>A fallback value is used when no results are found. Fallbacks are available for all macros.&nbsp;<\/p>\n\n\n\n<p>Let\u2019s understand the use of fallbacks through an example.<\/p>\n\n\n\n<p>Imagine we want to display posts that are also connected to the current post&#8217;s categories, as described in the <a href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#display-posts-related-by-terms-on-the-single-post-page\" target=\"_blank\" rel=\"noreferrer noopener\"><strong>Display posts related by terms on the single post page<\/strong><\/a> step. There is a new post called \u201cTest Post\u201d that doesn\u2019t have any terms associated with it yet. On the single page of that post, the query will simply return all published posts of that post type instead of returning zero results.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/testing-current-terms-macro-with-a-post-that-doesnt-have-terms.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/testing-current-terms-macro-with-a-post-that-doesnt-have-terms.webp\" alt=\"testing current terms macro with a post that doesn't have terms\" class=\"wp-image-51324\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/testing-current-terms-macro-with-a-post-that-doesnt-have-terms.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/testing-current-terms-macro-with-a-post-that-doesnt-have-terms-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/testing-current-terms-macro-with-a-post-that-doesnt-have-terms-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/testing-current-terms-macro-with-a-post-that-doesnt-have-terms-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/testing-current-terms-macro-with-a-post-that-doesnt-have-terms-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/testing-current-terms-macro-with-a-post-that-doesnt-have-terms-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>This is not the desired outcome, so we need to apply a fallback value that will be used if the macro doesn\u2019t find any results.\u00a0<\/p>\n\n\n\n<p>Click on the added macro to open a pop-up and press the \u201c<strong>Advanced settings<\/strong>\u201d<strong> <\/strong>button.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/accessing-the-advanced-settings-of-a-query-builder-macro.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/accessing-the-advanced-settings-of-a-query-builder-macro.webp\" alt=\"accessing the advanced settings of a query builder macro\" class=\"wp-image-51317\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/accessing-the-advanced-settings-of-a-query-builder-macro.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/accessing-the-advanced-settings-of-a-query-builder-macro-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/accessing-the-advanced-settings-of-a-query-builder-macro-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/accessing-the-advanced-settings-of-a-query-builder-macro-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/accessing-the-advanced-settings-of-a-query-builder-macro-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/accessing-the-advanced-settings-of-a-query-builder-macro-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>Keep the \u201cDefault Object\u201d <strong>Context<\/strong> and, in the <strong>Fallback <\/strong>field, specify a non-existent value \u2014 for example, a non-existent term ID like \u201c999999.\u201d<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/setting-a-fallback-value-for-macros-in-query-builder.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"618\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/setting-a-fallback-value-for-macros-in-query-builder-1024x618.webp\" alt=\"setting a fallback value for macros in query builder\" class=\"wp-image-51323\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/setting-a-fallback-value-for-macros-in-query-builder-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/setting-a-fallback-value-for-macros-in-query-builder-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/setting-a-fallback-value-for-macros-in-query-builder-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/setting-a-fallback-value-for-macros-in-query-builder-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/setting-a-fallback-value-for-macros-in-query-builder-600x362.webp 600w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/setting-a-fallback-value-for-macros-in-query-builder.webp 1824w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/div>\n\n\n\n<p>Now, the query returns zero results, which is the desired behavior.<\/p>\n<\/div><\/div>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"applying-the-created-query\">Applying the Created Query<\/h2>\n\n\n\n<div class=\"wp-block-group is-layout-constrained wp-block-group-is-layout-constrained\"><div class=\"wp-block-group__inner-container\">\n<p>You are free to use the created custom query with any widget that supports it. The most popular case, however, is applying the created query to a <strong>Listing Grid <\/strong>widget. Below, we will describe how to apply custom queries of the <strong>Query Builder <\/strong>in the<strong> Listing Grid <\/strong>widget\/block\/element in Elementor, Gutenberg (Block Editor), and Bricks.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"adjust-the-listing-in-elementor\">Adjust the Listing in Elementor<\/h3>\n\n\n\n<p>Open the page or template in the Elementor editor, add the <strong>Listing Grid<\/strong> widget, and select the previously created <strong>Listing<\/strong>. Adjust the settings in the <strong>General<\/strong> tab as needed.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-widget-in-elementor.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-widget-in-elementor.webp\" alt=\"adjusting the listing grid widget in elementor\" class=\"wp-image-51320\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-widget-in-elementor.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-widget-in-elementor-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-widget-in-elementor-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-widget-in-elementor-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-widget-in-elementor-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-widget-in-elementor-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>Then go to the <strong>Custom Query<\/strong> tab, enable the <strong>Use Custom Query<\/strong> toggle, and specify the <strong>Custom Query<\/strong> by selecting the one you have just created.<\/p>\n\n\n\n<div class=\"wp-block-image size-large is-resized\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-widget.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-widget.webp\" alt=\"applying a custom query of query builder in listing grid widget\" class=\"wp-image-51322\" style=\"width:840px;height:auto\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-widget.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-widget-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-widget-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-widget-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-widget-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-widget-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>Now, the listing should display items according to the results of the custom query. Publish the page or template to save the result.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"adjust-the-listing-in-gutenberg-block-editor\">Adjust the Listing in Gutenberg (Block Editor)<\/h3>\n\n\n\n<p>Head to the page or template where you want to place the <strong>Listing Grid<\/strong>, then open it in the WordPress block editor.\u00a0<\/p>\n\n\n\n<p>Find the <strong>Listing Grid<\/strong> block and place it on the page. Select the needed <strong>LISTING<\/strong> you have created beforehand. Adjust the settings in the <strong>General<\/strong> tab as needed.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-block-in-gutenberg.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-block-in-gutenberg.webp\" alt=\"adjusting the listing grid block in gutenberg\" class=\"wp-image-51318\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-block-in-gutenberg.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-block-in-gutenberg-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-block-in-gutenberg-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-block-in-gutenberg-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-block-in-gutenberg-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-block-in-gutenberg-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>Then go to the <strong>Custom Query<\/strong> tab, enable the <strong>Use Custom Query<\/strong> toggle, and specify the <strong>CUSTOM QUERY<\/strong> by selecting the one you have just created.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-block.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-block.webp\" alt=\"applying a custom query of query builder in listing grid block\" class=\"wp-image-51321\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-block.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-block-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-block-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-block-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-block-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-block-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>Now, the listing should display items according to the results of the custom query. Publish the page or template to save the result.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"adjust-the-listing-in-bricks\">Adjust the Listing in Bricks<\/h3>\n\n\n\n<p>Head to the page or template where you want to place the <strong>Listing Grid<\/strong>, then open it in the Bricks editor.\u00a0<\/p>\n\n\n\n<p>Find the <strong>Listing Grid<\/strong> element and place it on the page. Select the needed <strong>Listing<\/strong> you have created beforehand. Adjust the settings in the <strong>GENERAL<\/strong> tab as needed.<\/p>\n\n\n\n<div class=\"wp-block-image size-large is-resized\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-element-in-bricks.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-element-in-bricks.webp\" alt=\"adjusting the listing grid element in bricks\" class=\"wp-image-51319\" style=\"width:840px;height:auto\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-element-in-bricks.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-element-in-bricks-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-element-in-bricks-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-element-in-bricks-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-element-in-bricks-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/adjusting-the-listing-grid-element-in-bricks-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>Then go to the <strong>CUSTOM QUERY<\/strong> tab, enable the <strong>Use Custom Query<\/strong> toggle, and specify the <strong>Custom Query<\/strong> by selecting the one you have just created.<\/p>\n\n\n\n<div class=\"wp-block-image size-large\"><a href=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-element.webp\"><img loading=\"lazy\" decoding=\"async\" width=\"1824\" height=\"1100\" src=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-element.webp\" alt=\"applying a custom query of query builder in listing grid element\" class=\"wp-image-51325\" srcset=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-element.webp 1824w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-element-300x181.webp 300w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-element-1024x618.webp 1024w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-element-768x463.webp 768w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-element-1536x926.webp 1536w, https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/applying-a-custom-query-of-query-builder-in-listing-grid-element-600x362.webp 600w\" sizes=\"(max-width: 1824px) 100vw, 1824px\" \/><\/a><\/div>\n\n\n\n<p>Now, the listing should display items according to the results of the custom query. Save the page by pressing the corresponding button.<\/p>\n<\/div><\/div>\n\n\n\n<p>That\u2019s all. Now you learn about the macros of the <em>JetEngine<\/em><strong> Query Builder<\/strong> and learn how to use them in different use cases on your WordPress site.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Dive into the macros of Query Builder and learn how to use them in different use cases.<\/p>\n","protected":false},"author":8,"featured_media":0,"template":"","format":"standard","builder-category":[],"article-category":[405],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.9 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to Use JetEngine Macros in Query Builder \u2014 JetEngine | Crocoblock<\/title>\n<meta name=\"description\" content=\"Learn how use JetEngine macros in Query Builder to display posts on category and search pages, query posts by current meta values, and show authored posts on account pages on your WordPress site.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Use JetEngine Macros in Query Builder \u2014 JetEngine | Crocoblock\" \/>\n<meta property=\"og:description\" content=\"Learn how use JetEngine macros in Query Builder to display posts on category and search pages, query posts by current meta values, and show authored posts on account pages on your WordPress site.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/\" \/>\n<meta property=\"og:site_name\" content=\"Help Center\" \/>\n<meta property=\"article:modified_time\" content=\"2026-03-23T11:40:45+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/post-in-field-in-the-posts-query.webp\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"21 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/\",\"url\":\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/\",\"name\":\"How to Use JetEngine Macros in Query Builder \u2014 JetEngine | Crocoblock\",\"isPartOf\":{\"@id\":\"https:\/\/crocoblock.com\/knowledge-base\/#website\"},\"datePublished\":\"2026-03-23T11:40:42+00:00\",\"dateModified\":\"2026-03-23T11:40:45+00:00\",\"description\":\"Learn how use JetEngine macros in Query Builder to display posts on category and search pages, query posts by current meta values, and show authored posts on account pages on your WordPress site.\",\"breadcrumb\":{\"@id\":\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/crocoblock.com\/knowledge-base\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Articles\",\"item\":\"https:\/\/crocoblock.com\/knowledge-base\/articles\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Macros for Query Builder\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/crocoblock.com\/knowledge-base\/#website\",\"url\":\"https:\/\/crocoblock.com\/knowledge-base\/\",\"name\":\"Help Center\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/crocoblock.com\/knowledge-base\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/crocoblock.com\/knowledge-base\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/crocoblock.com\/knowledge-base\/#organization\",\"name\":\"Help Center\",\"url\":\"https:\/\/crocoblock.com\/knowledge-base\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/crocoblock.com\/knowledge-base\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2025\/04\/invert-crocoblock-logo.svg\",\"contentUrl\":\"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2025\/04\/invert-crocoblock-logo.svg\",\"caption\":\"Help Center\"},\"image\":{\"@id\":\"https:\/\/crocoblock.com\/knowledge-base\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to Use JetEngine Macros in Query Builder \u2014 JetEngine | Crocoblock","description":"Learn how use JetEngine macros in Query Builder to display posts on category and search pages, query posts by current meta values, and show authored posts on account pages on your WordPress site.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/","og_locale":"en_US","og_type":"article","og_title":"How to Use JetEngine Macros in Query Builder \u2014 JetEngine | Crocoblock","og_description":"Learn how use JetEngine macros in Query Builder to display posts on category and search pages, query posts by current meta values, and show authored posts on account pages on your WordPress site.","og_url":"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/","og_site_name":"Help Center","article_modified_time":"2026-03-23T11:40:45+00:00","og_image":[{"url":"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2023\/05\/post-in-field-in-the-posts-query.webp"}],"twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"21 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/","url":"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/","name":"How to Use JetEngine Macros in Query Builder \u2014 JetEngine | Crocoblock","isPartOf":{"@id":"https:\/\/crocoblock.com\/knowledge-base\/#website"},"datePublished":"2026-03-23T11:40:42+00:00","dateModified":"2026-03-23T11:40:45+00:00","description":"Learn how use JetEngine macros in Query Builder to display posts on category and search pages, query posts by current meta values, and show authored posts on account pages on your WordPress site.","breadcrumb":{"@id":"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/crocoblock.com\/knowledge-base\/jetengine\/macros-for-query-builder\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/crocoblock.com\/knowledge-base\/"},{"@type":"ListItem","position":2,"name":"Articles","item":"https:\/\/crocoblock.com\/knowledge-base\/articles\/"},{"@type":"ListItem","position":3,"name":"Macros for Query Builder"}]},{"@type":"WebSite","@id":"https:\/\/crocoblock.com\/knowledge-base\/#website","url":"https:\/\/crocoblock.com\/knowledge-base\/","name":"Help Center","description":"","publisher":{"@id":"https:\/\/crocoblock.com\/knowledge-base\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/crocoblock.com\/knowledge-base\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/crocoblock.com\/knowledge-base\/#organization","name":"Help Center","url":"https:\/\/crocoblock.com\/knowledge-base\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/crocoblock.com\/knowledge-base\/#\/schema\/logo\/image\/","url":"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2025\/04\/invert-crocoblock-logo.svg","contentUrl":"https:\/\/crocoblock.com\/knowledge-base\/wp-content\/uploads\/2025\/04\/invert-crocoblock-logo.svg","caption":"Help Center"},"image":{"@id":"https:\/\/crocoblock.com\/knowledge-base\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/crocoblock.com\/knowledge-base\/wp-json\/wp\/v2\/article\/39655"}],"collection":[{"href":"https:\/\/crocoblock.com\/knowledge-base\/wp-json\/wp\/v2\/article"}],"about":[{"href":"https:\/\/crocoblock.com\/knowledge-base\/wp-json\/wp\/v2\/types\/article"}],"author":[{"embeddable":true,"href":"https:\/\/crocoblock.com\/knowledge-base\/wp-json\/wp\/v2\/users\/8"}],"wp:attachment":[{"href":"https:\/\/crocoblock.com\/knowledge-base\/wp-json\/wp\/v2\/media?parent=39655"}],"wp:term":[{"taxonomy":"builder-category","embeddable":true,"href":"https:\/\/crocoblock.com\/knowledge-base\/wp-json\/wp\/v2\/builder-category?post=39655"},{"taxonomy":"article-category","embeddable":true,"href":"https:\/\/crocoblock.com\/knowledge-base\/wp-json\/wp\/v2\/article-category?post=39655"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}