Cannot Access Subform Display Order in Deluge

Cannot Access Subform Display Order in Deluge

As highlighted in this community post, we still have to deal with the significant limitation of not being able to access the user-sorted order of subform rows through Deluge. This creates a major disconnect between the UI capabilities and backend automation, and I'm hoping the Zoho team can address this in a future update.

The Issue
Zoho Creator now offers two distinct subform sorting methods:
  • Drag and drop: Manual, user-controlled sorting where users reorder rows by dragging them into their preferred sequence. The sort order is arbitrary and based on user preference, not field values.
  • By predefined column: Automatic, system-controlled sorting based on a specified column that happens whenever the record is created or updated. The sort order is predictable and based on field values.
However, these sorted orders are completely invisible to Deluge scripts. When you iterate through subform rows using for each loops, you get the records in their original creation order—regardless of whether the subform uses drag-and-drop sorting or automatic column-based sorting.

The Problem
Regardless of which sorting method is configured, the display order is trapped in the UI layer—Deluge has no way to access it.
Sorting Method What User Sees What Deluge Sees Result
Drag and Drop
User drags Row 5 to position 1
Row 5 appears at the top of the subform Row 5 is still in position 5 (creation order) ✗ Custom order completely ignored
Predefined Column
Subform set to sort by "Priority" (High to Low)
Rows automatically displayed in priority order after save Original creation order (Row 1, Row 2, Row 3...) ✗ Automatic sorting not reflected
Either Method
User clicks "Generate Report" button
Expects report to match displayed order Report generated in creation order ✗ Output doesn't match user's view
Current Limitations
Regardless of which sorting method is enabled, you cannot:
  • Loop through subform rows in the display order (whether drag-and-drop or predefined column)
  • Access any "sort order" or "display position" field
  • Determine which column is used for automatic sorting
  • Detect if drag-and-drop sorting is enabled
  • Update a field (like "Sequence Number") to reflect the sorted order
  • Generate custom reports in Pages or Deluge that respect the subform's display order
Important Note: Record Templates do preserve the re-sorted order when generating PDFs or documents. This means basic reporting through record templates works correctly. However, for any advanced reporting—such as custom HTML in Deluge, Pages, or programmatic data processing—the sorted order is completely inaccessible, making it impossible to replicate what record templates can do.
Example: The Disconnect
Here's a real-world scenario that demonstrates the problem:
// SCENARIO: Task subform is configured to sort by "Priority" column (High to Low)
// This is automatic sorting - happens when record is created/updated
// User clicks a button to "Generate Prioritized Task List"

// What the developer writes:
for each task in input.Task_Subform
{
    task_list = task_list + task.Task_Name + "\n";
}

// EXPECTED OUTPUT (what user sees on screen after save):
// 1. Fix critical bug (High)
// 2. Review code (High)  
// 3. Update documentation (Medium)
// 4. Refactor old code (Low)

// ACTUAL OUTPUT (what Deluge produces):
// 1. Update documentation (Medium)     ← Created first
// 2. Fix critical bug (High)           ← Created second  
// 3. Refactor old code (Low)           ← Created third
// 4. Review code (High)                ← Created fourth

// Result: User confusion and loss of trust in the system
// Note: The same problem occurs with drag-and-drop sorting!
Impact: The generated output doesn't match what the user sees on screen, creating confusion and undermining user confidence. This affects both automatic sorting (by predefined column) and manual sorting (drag-and-drop).
Attempted Workarounds (All Inadequate)
Workaround Approach Implementation Problems Status
Manual Sequence Field Add a "Sequence" number field that users manually update - Requires users to manually type numbers
- Defeats purpose of drag-and-drop sorting
- Doesn't work with predefined column sorting
- Prone to errors and gaps
- Poor user experience
✗ Not viable for real-world use
Sort in Deluge Instead Use Deluge's .sort() function on subform collection - Only works if you know the predefined sort column
- Cannot replicate custom drag-and-drop order at all
- Assumes single-column sorting
- Doesn't help if user needs multi-column sort
- Still a workaround for what should be automatic
⚠ Partial solution for predefined column only
JavaScript Widget Build custom UI using JavaScript Widget instead of native form - Requires abandoning native form entirely
- Must rebuild entire subform interface from scratch
- Significant development and maintenance overhead
- Loses all native form features and functionality
- Defeats the purpose of using Creator's built-in forms
✗ Not viable - abandons native functionality
What Should Happen Instead
Proposed Solution 1: Display Order Field Add a system-generated field that reflects the current display order:
for each task in input.Task_Subform.sortBy("display_order")
{
    // Process tasks in the order the user sees them
    info task.Task_Name;
}
Proposed Solution 2: Sort State Information Provide access to the current sort configuration and type:
sort_info = input.Task_Subform.getSortState();
// Returns: 
// {"type": "predefined_column", "column": "Priority", "direction": "desc"}
// or {"type": "drag_and_drop"}

if(sort_info.get("type") == "drag_and_drop")
{
    // Drag-and-drop enabled, access via display_order
    sorted_tasks = input.Task_Subform.sortBy("display_order");
}
else if(sort_info.get("type") == "predefined_column")
{
    // Predefined column sorting, replicate that sort
    sorted_tasks = input.Task_Subform.sortBy(sort_info.get("column"), sort_info.get("direction"));
}
else
{
    // No sorting configured, use creation order
    sorted_tasks = input.Task_Subform;
}
Proposed Solution 3: Built-in Sort Preservation Automatically update a hidden "display_sequence" field whenever the display order changes (whether through predefined column sorting or drag-and-drop), making it accessible to Deluge:
// System automatically maintains display_sequence field for both sorting methods
for each task in input.Task_Subform.sortBy("display_sequence")
{
    // Always iterates in display order
    // Works regardless of sorting method (predefined column or drag-and-drop)
    info task.Task_Name;
}
Any of these solutions would bridge the gap between UI capabilities and backend automation for both sorting methods.
Real-World Impact
This limitation affects critical business processes:
  • Project Management (Predefined Column): Subform automatically sorts tasks by priority, but automated status reports generate in creation order, not priority order
  • Meeting Agendas (Drag and Drop): Users arrange agenda items manually via drag-and-drop, but generated PDF shows items in original entry order
  • Invoice Line Items (Drag and Drop): Users reorder line items for presentation purposes, but printed invoices ignore the arrangement
  • Course Curriculum (Predefined Column or Drag and Drop): Instructors order lessons logically (either by lesson number or manual arrangement), but student-facing materials display in database order
  • Checklist Applications (Predefined Column): Subform automatically sorts by due date or priority, but automated reminders follow original creation order
  • Product Catalogs (Drag and Drop): Users arrange products by preference or featured status, but exports and integrations ignore the curation

User Experience Impact: Whether using predefined column sorting (automatic) or drag-and-drop sorting (manual), when users see data in a particular order on screen and the system's automation ignores it, it creates frustration and erodes trust. Users expect that if they can see data in a certain order, the system should be able to work with it in that order.

Request to Zoho Team

Can this be addressed in a future update?

This is a fundamental disconnect between what users see in the UI and what developers can access in code. Both sorting methods (predefined column and drag-and-drop) suffer from this limitation. The current implementation forces developers to choose between:

1. Disable Sorting
Remove sorting capabilities (both predefined column and drag-and-drop) to avoid user confusion when automation doesn't respect display order
2. Accept Mismatch
Allow users to sort but acknowledge that automation will produce unexpected results

Neither option is acceptable for professional applications.

Community Input Requested: Has anyone else encountered this limitation or found a reliable workaround? This affects any application where subform ordering matters to end users.



      Zoho Campaigns Resources


        • Desk Community Learning Series


        • Digest


        • Functions


        • Meetups


        • Kbase


        • Resources


        • Glossary


        • Desk Marketplace


        • MVP Corner


        • Word of the Day


        • Ask the Experts


          Zoho CRM Plus Resources

            Zoho Books Resources


              Zoho Subscriptions Resources

                Zoho Projects Resources


                  Zoho Sprints Resources


                    Zoho Orchestly Resources


                      Zoho Creator Resources


                        Zoho WorkDrive Resources



                          Zoho CRM Resources

                          • CRM Community Learning Series

                            CRM Community Learning Series


                          • Tips

                            Tips

                          • Functions

                            Functions

                          • Meetups

                            Meetups

                          • Kbase

                            Kbase

                          • Resources

                            Resources

                          • Digest

                            Digest

                          • CRM Marketplace

                            CRM Marketplace

                          • MVP Corner

                            MVP Corner




                            Zoho Writer Writer

                            Get Started. Write Away!

                            Writer is a powerful online word processor, designed for collaborative work.

                              Zoho CRM コンテンツ




                                ご検討中の方

                                  • Recent Topics

                                  • Admin asked me for Backend Details when I wanted to verify my ZeptoMail Account

                                    Please provide the backend details where you will be adding the SMTP/API information of ZeptoMail Who knows what this means?
                                  • Mass import of documents into Zoho Writer

                                    I'm using Google's word processor at the moment but feel that Zoho does a better job (on the online apps market). Iwant to move my documents (about 50-70) to Zoho but it seems to me that I have to import them seperately. Is it already possible to upload several documents at a time or is this a forthcoming feature? Cheers Rolli :?:
                                  • When will it be possible to edit Subform records via either views or tabular reports?

                                    Hey there, data maintenance often requires mass update of quite a lot of records. While this is a piece of cake via either List view or Zoho sheet view, the same cannot be carried out for subform records yet. When one of the two options will be made available?
                                  • Add System Pre-Defined Lookup Field to Subform?

                                    Hi there! New to using Zoho, so this may already exist, but I'm having trouble figuring it out. Is there a way to get the system pre-defined Account Lookup field (in our case, renamed to Company Name), as the starting point for a subform? In our company,
                                  • Duplicating and referencing datasets

                                    I am moving from PowerBI to Zoho Analytics and while I find Zoho easier to use in many ways, there is one function that I use in PowerBI that I have not been able to find in Zoho.   I have several data sets that I need to modify in different ways to get
                                  • How we cut CRM updates from ~20 minutes down to 2, our real workflow

                                    Updating the Zoho CRM after every call used to be one of the biggest time sucks for our team. By the time you write your notes, clean them up, fill in the fields, and log everything properly… you’ve easily lost 15–20 minutes per call. We started experimenting
                                  • Add home page or dashboard in CRM customer portal

                                    is it possible to add home page or dashboard in CRM customer portal?
                                  • User Tips: How to change the the label display name of a system defined field

                                    Most users know how to change field label names via Settings > Modules & Fields but if you want to change the name of a system defined field you can’t as there is no “edit properties” option.  However with a simple hack you can edit any system defined
                                  • Search not working!

                                    I have items in my notebook tagged but when I search for a tag nothing comes up! Any fix for this?
                                  • Zoho CRM Community Digest - October 2025 | Part 1

                                    Hello Everyone! Here's a quick recap of first two weeks of October! Product Updates: Zoho CRM Android App Update: Surveys, Blueprints, and Smarter Mobile Features! Zoho CRM’s Android app just got a useful upgrade. You can now share records, upload your
                                  • Automate onboarding emails with CRM Workflow and Accounts module

                                    We’re a B2B SaaS company selling to public-sector organisations. Each organisation is stored as an Account in Zoho CRM, and each organisation typically has multiple associated Contacts. Our backend syncs product-usage data (setup status, user activity,
                                  • Using a CRM Client Script Button to create a Books Invoice

                                    Hello, I need help handling error messages returned to my client script from a function. The scenario I have setup a client script button which is available from each Deal. This CS executes a crm function, which in turn creates an invoice based on the
                                  • Important update: Enhanced security measures for account operations in Zoho Cliq

                                    Greetings from the Zoho Cliq team! We’d like to share an important security update that has an influence on some admin actions such as password reset, MFA reset, and MFA backup code generation. What’s changing? With our latest security enhancements, these
                                  • Sales Receipts Duplicating when I run reports why and how do we rectify this and any other report if this happens

                                    find attached extract of my report
                                  • Can I execute two 'functions' when completing a mail merge from CRM?

                                    Hi, I have set up a mail merge from CRM Deals to a template. I want a copy of this to be saved in Workdrive, and then a copy also saved back into the deal record from which the merge occurred. I can do both independent of each other, and managed to get
                                  • No Functional Autosave or Manual Save Button

                                    Application : Zoho Notebook So I wanted to try Zoho Notebook(On Ubuntu) as an application, I installed the application and went solving my LeetCode problems visually(Drawing mode), at one point the app just stopped saving anything... Every time I tried
                                  • Enterprise subscription support

                                    My organization sells subscription services to enterprise customers, which is a different model from the consumer subscription model that Zoho Billing has been designed to support and I beleve this capability should be added. An enterprise subscription
                                  • Issue with Creator's IF logic

                                    Hi, I found the following code produces unexpected results: if(-1.0 < 0.0000000) {       info "True"; } else {       info "False"; } if(-1.0 < 0.000000) {       info "True"; } else {       info "False"; } The output returned is: False True However, the
                                  • Need option to send Package PDF in shipment email (Shipment PDF is missing Lot info)

                                    Is there any way to automatically attach the Package PDF instead of (or alongside) the Shipment PDF in the notification emails? We really need this feature because the default Shipment PDF creates a blind spot for our customers. It does not display Batch/Lot
                                  • zoho creator view is not present in the workspace and blank reports

                                    Hi Support,  Users who have "write" permissions keep getting this error for all of our embedded reports all of a sudden. See screen shot below: Meanwhile, my developer permissions account sees a blank screen in view and edit mode as shown in the screenshots
                                  • Customize portal email template

                                    Can i fetch only first name of the user in portal email template instead of the below code Hi ${User.FULL_NAME}
                                  • Can't we let users decide which options they'd like to add at embed widget?

                                    It seems embed widget DOES NOT offer a feature, where users can choose options upon subscribing plans. What Zoho has instead, is that admins have to manually create plan with options. How come no one in Zoho dev team never raised issue about usability
                                  • Reupload and rename from one field to another field (file upload)

                                    Hi Everyone, Sorry, i have question to use invoke url for rename and reupload attachments file to another field. Tested on development mode. Zoho C6. Refer to https://www.zoho.com/creator/help/api/v2/upload-file.html look my error notification. Does anyone
                                  • Printing Multi-Page Reports (PDF Export)

                                    Hi, I am moving a report from Google's Looker Studio to Zoho Analytics and trying to reproduce the Looker page by page dashboard editing experience. With Google, what you see is what you get when you print to PDF. But I can't seem to create the same experience
                                  • Resume Harvester: New Enhancements for Faster Sourcing

                                    We’re excited to share a set of enhancements to Resume Harvester that make sourcing faster and more flexible. These updates help you cut down on repetitive steps, manage auto searches more efficiently, and review candidate profiles with ease. Why we built
                                  • I NEED TO NUMBER TO TEXT NO HERE

                                    =NUMBERTEXT NEEED
                                  • Error: View is not present in the workspace

                                    When saving a dashboard, user receives a popup with the following error. "View is not present in the workspace" What does this mean or refer to? There is no further insight given.
                                  • Dear Zoho CEO: Business Growth is about how you prioritise!

                                    All of us in business know that when you get your priorities right, your business grows. Zoho CRM and Zoho Books are excellent products, but sadly, Zoho Inventory continues to lag behind. Just this morning, I received yet another one-sided email about
                                  • Is there any way to send an Excel received by email to Dataprep?

                                    Every day I receive an email alert with an Excel file that I want to process through a Dataprep pipeline. To do this, I need to: -Save the file to disk -Open the pipeline -Run the pipeline -Update the source -Several clicks to select and open the saved
                                  • Bin Locations

                                    Dear all, I am wondering if someone has the ability to develop the bin locations option for zoho inventory (integrated with zoho books) Regards, Ryan
                                  • Create and populate a record in an instant: Introducing zero-shot field prompting to Zia's ICR

                                    A couple of months ago, we upgraded our in-house AI image detection and validation tool, Zia Vision, with intelligent character recognition (ICR). By training Zia with sample images, you could create and enrich CRM records with data extracted from standard
                                  • How to Prevent Users From Skipping LMS Videos in Zoho People

                                    How to Prevent Users From Skipping LMS Videos in Zoho People Hello Zoho Developers, In this blog, we will quickly look at how you can stop users from skipping or fast-forwarding videos in Zoho People LMS. Zoho People provides a feature called Disable
                                  • Sent mail sort by date disappeared

                                    Hello, We used to be able to sort the emails by date in the sent folder, but this feature has recently disappeared. Can we bring it back?
                                  • [Integration Edition] Deluge Learning Series – Custom API with Deluge | November 2025

                                    We’re excited to conclude this four-month Integration Edition of the Deluge Learning Series: Session 1 – Integrating Zoho Apps with Deluge Using Built-In Integration Tasks Session 2 – Integrating Zoho Apps with Deluge Using invokeURL and invokeAPI Session
                                  • Automate Backups

                                    This is a feature request. Consider adding an auto backup feature. Where when you turn it on, it will auto backup on the 15-day schedule. For additional consideration, allow for the export of module data via API calls. Thank you for your consideration.
                                  • Tips for Organizing Workflows and Improving Team Coordination in Zoho

                                    Hi everyone, I’m looking for some general advice on how different teams are organizing their daily work within Zoho’s apps. Our team recently expanded, and we’re trying to streamline how tasks, discussions, and documents are shared so everything stays
                                  • Prevent user from viewing all records?

                                    I have a report that is meant to be used by vendors to view only the records that are assigned to them. All the vendor information is stored in a separate application, so I need to call a function to get the current user's ID (not the zoho user ID). The report settings criteria doesn't support using function calls, so instead I'm embedding the report in an html page like this: if (thisapp.Global.CurrentUserIs("Vendor")) {       personID = common.getLoggedInPersonID();       query = "Assigned_Vendor.ID="
                                  • Zoho Site pages not displaying in iframes

                                    I simply want to show a Zoho Site page inside an iframe on another non Zoho website. When testing this across many browsers, the iframe content simply does not appear. IE reports that the host does not allow their content to be displayed in iframes. Very disappointing. Is there a way around this please? Here is the URL of the page I would like to appear in an iframe. http://ips-properties-to-rent.zohosites.com
                                  • Zoho Inventory as connector in Zoho Creator

                                    Hello, It doesn't appear that Zoho Inventory is one of the many built in connectors in Zoho Creator? I see that there are non-Zoho inventory applications that have built in connectors such as Cin7, which leads me to believe that I'm missing something
                                  • Send Zoho Forms Link using Zoho CRM Email Templates

                                    I have set up Zoho Forms and CRM integration to pre-populate data from Zoho CRM to Zoho Forms. The setup is working fine. I have also created an email template in the Zoho CRM deals module to send Zoho forms links. So when I send an email using that template
                                  • Next Page