Multi Level Hierarchical Query

Multi Level Hierarchical Query

Hi guys

I have a situation where i am trying to extract the descendants of a particular entry. 

So long story short, i have the Account table with Agency (A) id = 1, and that has child Agency (B) id = 2. This child agency (B) has a child agency (C) id = 3. This child agency (C) has a child agency (D) id = 4. 

So in essence we have have a pyramid setup where each level has other child agencies underneath. The number of levels differ per the preceding Agency.

My question now is, in Analytics how do i write a heirachical query that takes into account all the levels (or rather extract). 

As it is if i write this query: select * from Account where id = 1, it only brings up the first level (Agency B) but i want to have that query show all the agencies (A, B, C, D)

    • Sticky Posts

    • What's New in Zoho Analytics - February 2026

      Hello Users! We're back with another round of updates for Zoho Analytics. This month's release focuses on giving you greater flexibility in how you visualize, manage, and act on your data - with new features like custom visualizations, remote MCP server,
    • What's New in Zoho Analytics - January 2026

      Hello Users! We are starting the year with a strong lineup of updates, marking the beginning of many improvements planned to enhance your analytics experience. Explore the latest improvements built to boost performance, simplify analysis, and help you
    • What's New in Zoho Analytics - November 2025

      We're thrilled to announce a significant update focused on expanding your data connectivity, enhancing visualization capabilities, and delivering a more powerful, intuitive, and performant analytics experience. Here’s a look at what’s new. Explore What's
    • What's New in Zoho Analytics - October 2025

      Hello Users! We're are back with a fresh set of updates and enhancements to make data analysis faster and more insightful. Take a quick look at what’s new and see how these updates can power up your reports and dashboards. Explore What's New! Extreme
    • What’s New in Zoho Analytics – September 2025

      Hello Users!! In this month’s update, we’re raising the bar across multiple touchpoints, from how you bring in data, plan and track projects to how you design and brand your dashboards. We’ve added the all-new Gantt chart for project visualization, expanded
    • Recent Topics

    • since the new interface of ZOHO writer can't turn of automatic reminder option for merge documents

      Since the new interface of ZOHO writer I have this problem. I have a large set of templates that I use to send documents to ZOHO Sign. But now in all those templates the box for Sending reminders is ticked, which i don't want. But even if I untick the
    • Sales Allowed Beyond Available Stock and Payment Recorded Without Restriction

      Hi, While testing in Zoho Inventory, I noticed that a sales order can be created with a quantity exceeding the available stock in the selected warehouse. In my case: Available stock: 5 units Ordered quantity: 6 units Despite this: I was able to convert
    • Function #25: Automatically generate purchase orders from a sales order

      We kicked off the "Function Fridays" series with the goal of helping you automate your everyday accounting tasks. As we delve into today's post, I'm delighted to announce that we're here to present the 25th custom function in this series. While it is
    • How can I add Material cost to a project?

      Hello, We use Zoho project to manage scheduled work. This consists in labour tasks and matrials cost. How can I add the material budget, then teh cost to the project? Thanks Barbara
    • Users I've shared the sheet with cannot use the Custom Functions

      Hi, I have a Zoho Sheet worksheet that I shared to 2 colleagues, giving them full access: In that worksheet, I created a button with a custom Deluge function and it works flawlessly for me: For those I shared the worksheet to, when they click the button,
    • Mail bounces due to bad reputation

      Good evening. I'm seeing these errors from both hotmail/outlook and yahoo, as well as hard bounce from Virgin Media and talktalk for some time now. Bounce category: Connection issues Reason: uncategorized-bounce Message: 4.7.650 The mail server [136.143.188.237]
    • Automation Series #3: Macro vs Workflow in Zoho Desk

      Workflows vs Macros in Zoho Desk: Choosing the right help desk automation This post is part of the "Desk Automation Series," Chapter 1. Through this series, we will help you choose the right automation type in Zoho Desk by comparing commonly confused
    • Limiting the form - Zoho People

      Hi Team, I would like to limit the number of form/request submissions for employees within a given month. For example, if an employee has already submitted 3 requests in the current month, they should not be allowed to submit any further requests. An
    • Introducing our new 'Extension Development' Series!

      Hello users, We're excited to launch a new series on 'Building Extensions in Zoho Sprints' where the workspace owner or developers can learn to customize the workspace to meet their unique or niche requirements. Each post in this series will guide you
    • Product Updates in Zoho Workplace applications | March 2026

      Hello Workplace Community, Let’s take a look at the new features and enhancements that went live across all Workplace applications for the month of March. Zoho Mail Create Collections Under Categories in Bookmarks Create multiple collections under categories
    • Every time an event is updated, all participants receive an update email. How can I deactivate this?

      Every time an event is updated in Zoho CRM (e.g. change description, link to Lead) every participant of this meeting gets an update email. Another customer noticed this problem years ago in the Japanese community: https://help.zoho.com/portal/ja/community/topic/any-time-an-event-is-updated-on-zohocrm-calendar-it-sends-multiple-invites-to-the-participants-how-do-i-stop-that-from-happening
    • How to install Widget in inventory module

      Hi, I am trying to install a app into Sales Order Module related list, however there is no button allow me to do that. May I ask how to install widget to inventory module related list?
    • Credit card transactions are backwards after importing statements

      I am new to Zoho Books so I'm importing my firm's bank and credit card statements in. My credit card statements have a single column with negative numbers so that is the option I chose. But when I went to categorize the credit card transactions, I can
    • BMO bank connection not working with either Yodlee or Plaid

      Been experiencing this issue for almost a month now. Anyone else?
    • How to reduce inventory valuation when not tracking individual items?

      We purchase clothing items wholesale, embroider them with a company's logo, then resell. The garment style, size, color, etc. changes according to a customer's desire, so we don't track the individual item's purchase within Zoho Inventory unless there's
    • i want to delete organization or tranfer ownership

      I accidentally created a Zoho organisation and now I cannot accept an invite from another organisation. I am the Super Admin and cannot leave. Please either delete my organisation or transfer ownership so I can leave.
    • Stage-probability mapping feature in custom module

      Hi, I'm building a custom module for manage projects. I would like to implement the stage-probability feature that Potentials has. Is this possible?
    • Mastering Zia Match Scores | Let's Talk Recruit

      Feeling overwhelmed by hundreds of resumes for every job? You’re not alone! Welcome back to Let’s Talk Recruit, where we break down Zoho Recruit’s features and hiring best practices into simple, actionable insights for recruiters. Imagine having an assistant
    • Zoho Books - France

      L’équipe de Zoho France reçoit régulièrement des questions sur la conformité de ses applications de finances (Zoho Books/ Zoho Invoice) pour le marché français. Voici quelques points pour clarifier la question : Zoho Books est un logiciel de comptabilité
    • Zoho Home Tasks View - any way to add conditional formatting?

      Hello! Is there any way to add conditional formatting to the tasks window under Home Page? Id like tasks to be shown in green/yellow and red depending on its task date. I know Classic View shows colorfull icons: But its not possible to add any custom
    • User Name in Zoho Cliq Not Updating Across Apps?

      We updated the name of a user in Zoho. (From Sue to Taylor) Her name has not been updated in Cliq on all apps. When in Zoho One, if I go to Cliq directly, it is correct, but if I am in another app, and the Cliq bar pops up on the bottom, it will be the
    • New Customization options in the module builder: Quick Create and Detail view

      Hello everyone, We have introduced two new components to the module builder: Quick create and Detail view. The Quick Create Component It is a mini form used to create a record and associate it to the parent record from a lookup field. For example, if you have a Deals lookup in the Contacts module, then you can associate existing deals or create a deal and associate it with the contact. You can customize this Quick Create form by adding standard as well as custom fields. There is no limit to the number
    • How do I automate my package and shipment process

      Hey, I have a very basic problem regarding automating my package and shipment. My business does not require me to have those modules and manage them currently and since I'm new to zoho I want to start with just the basics. I just need to automatically
    • Announcing Zoho Sheet desktop app for macOS and Windows (Beta)

      Hello Sheet users, We know you’ve been waiting for this one. It has always been the top priority on our roadmap to provide a single native desktop app for macOS and Windows that works both online and offline. Today, we are excited to announce that the
    • zoho creator panel add formula

      Hello. I'm using zoho panels which works good for me but i need to add an extra calculation the predefined sum function provided by zoho. not sure if this is possible? The code zoho is generating for the sum is as follows; <text margin='0px' padding='0px'
    • How to take result of calculation in a form and subtract from a value in another form

      I'm using the following code on successful form submission to perform a calculation and enter the result into a field a shown below input.Space_Used = ifNull(input.Area_In_Square_Meters,0) * ifNull(input.Total_Stock,0); I now need the result above, the
    • Missing Fields in Lead Conversion Mapping

      I’ve been using Zoho CRM since 2013 to manage leads and convert them into contacts and jobs. When I convert a lead to a customer, I create a new contact and a job. Previously, this process automatically transferred key information from the lead to the
    • Mass email from Report output

      Hi, I'd like to send a mass email based on a report output. The report is pulling multiple information from linked modules. Each line of the report ends up with a contact name, email and multiple field values pulled from the linked modules (some are custom
    • What's New in Zoho Analytics - February 2026

      Hello Users! We're back with another round of updates for Zoho Analytics. This month's release focuses on giving you greater flexibility in how you visualize, manage, and act on your data - with new features like custom visualizations, remote MCP server,
    • Understanding tasks

      So we have a module linked to contacts called Equipment and that in turn has a related module called service calls. Often on a service call we want add a task but we are not able. I think it needs a link to the contact. WE therefore tried to add tasks
    • Cross Module Filtering – Use Fields from Lookup modules in Custom Views criteria and Advanced Filters

      Hello everyone, Zoho CRM now enables you to achieve deeper filtering of records in a module, using fields of a lookup, thereby enhancing your data management experience manifold. This filtering based on lookup module fields is now available in advanced
    • Related Lists in Email Templates

      Hi Zoho team, I would love to see a feature where related list information can easily be added to an email template (instead of mail merge). I have a client who books flights for their customers. They do this through a Flights module so all booked flights
    • Auto-sync field of lookup value

      This feature has been requested many times in the discussion Field of Lookup Announcement and this post aims to track it separately. At the moment the value of a 'field of lookup' is a snapshot but once the parent lookup field is updated the values diverge.
    • Introducing SlyteUI : From Idea to a Working Interface in Minutes

      Hello everyone! Are you spending hours building basic UIs? Does even the smallest customization feel like a major task? CRM customization should feel intuitive and straightforward, not time consuming or exhausting. SlyteUI makes this possible by simplifying
    • need to add tax in servce and items

      please give access to add gst or tac to add in service and parts
    • Blueprint transitions on locked records

      We use the ability to automatically lock records (quotes, sales orders, etc.) based on criteria, such as stage. For instance, if a quote has been sent to a client, the quote is then locked for further edits. Our ideal quote stage process is: Draft>Sent>Won.
    • Lead Entry Strategy

      Hi there. Was wondering if anybody could share their strategy around lead entry into Zoho CRM. One of the challenges with Zoho CRM is a lead requires a last name. We want to capture companies that operate within our addressable market, and we often don't
    • Social posts not saving as drafts or posting

      Over the past two days, I have written and modified the same post for 5 different channels 4 different times. They will neither save as draft, nor go through and load in the scheduler, nor will they post when I try to push it live now. In every case,
    • Introducing user groups, roles, and profiles in Zoho Sign

      Hello, Today, we're excited to unveil user groups, roles, and profiles to offer granular access controls in Zoho Sign. These help administrators manage document visibility and accessibility based on assigned user roles and permission sets. User groups:
    • On Duty Requests - Zoho People Data

      Hello Team, We are currently using the On Duty Form to record Work From Home (WFH) requests in our organization. However, we are facing an issue where pending On Duty requests are not appearing in the Attendance Module. For example, if I submit On Duty
    • Next Page