Skip to main content A new Salesforce certification experience is coming July 21st. Discover how exams will be delivered in Pearson VUE, what it means for you, and ways to prepare. Learn more.

Feed

Connect with fellow Trailblazers. Ask and answer questions to build your skills and network.

Build a flex prompt  

getting the same error when i build a prompt template that i can't find the experience 

 

getting the same error when i build a prompt template that i can't find the experience

 

 

but it's added and i can see it.  ive done it twice now in two diff environments.  

 

TRAILBLAZER ERROR 2.png

 

 

 

#Trailhead Challenges  #Trailhead

0/9000

At first I used a code from google, which was using SessionID for authentication. It was working smooth when called from Anonymous window but when I used it in the LWC Controller class as a method, it was throwing Invalid Session ID error. After a little chatgpt and googling I found that's supposed to happen and I had to use the Named Credentials. To use the Named Credentials I needed to have the Auth. Provider and for that I needed to have the Connected App.  

 

There was one existing Auth. Provider which had my org's url in the auth and token provider but when I used it in my new named credentials, it throwed some error, I am guessing its because the Auth. Provider didn't had any callback url, so that's why the named credential could not authorize using it.  

 

Let me know if there's a way I can use that Auth. Provider directly in my Apex code for this.  

 

Currently, I am using the named credentials created by me, to create the reports.  

 

Please let me know if there's any workaround so I don't have to create all these. 

 

Any help is appreciated, Thanks! 

 

Here's how it looks right now

String endpoint = 'callout:MyOrgAPI/services/data/v64.0/analytics/reports';

HttpRequest req = new HttpRequest();

req.setEndpoint(endpoint);

req.setMethod('POST');

req.setTimeout(20000);

req.setHeader('Content-Type', 'application/json');

req.setBody(reqBody);

Http http = new Http();

HTTPResponse res = http.send(req);

#API  #Integration  #Reports

0/9000

Hey all! I’m a Salesforce Admin at a SaaS company, and we’re trying to make a decision on how to handle returning customers who were previously churned. It doesn’t happen super often, but we’ve had a few customers come back recently and it’s raising some questions. 

 

The main issue, is we integrate with other solutions (Intacct/Adaptive Planning) for financial and forecasting. A new Intacct ID is required when they return, which makes it cleaner

to create a brand new Account in Salesforce. On the other hand, I don’t love duplicating Accounts because we lose historical context in the CRM, and it can get messy for our Sales, CS, and Support teams. 

 

I’m wondering how others handle this — reopen or create new? 

 

Here’s the options we're considering:

Option 1: Reopen the old Account

  • Pros: Keeps CRM clean, retains full history, no confusion in reporting
  • Cons: Can cause confusion with financial/forecast planning integrations

Option 2: Create a new Account

  • Pros: Clean slate for integrations, financial and planning teams prefer this
  • Cons: Duplication in CRM, harder to trace lifecycle, need to relink Contacts/Cases/etc.

Possible Hybrid Approach:

  • New Account gets created
  • We link it back to the original via a custom lookup
  • Copy data onto the new account with apex/flows to ensure data cleanliness

Curious to hear how others handle this in integrated orgs. If you’ve dealt with this before, what worked for you? Any suggestions or best practices to share with this use case? Thanks in advance! #Salesforce Admin #Sales Cloud #Data Management

2 answers
  1. Today, 11:18 AM

    We use 1 Account record, also.  Our Finance Team can choose to use the existing Intacct ID (default) or create a new one.

0/9000

I am working on a screen flow and it has got some grids/templates/request type so that the users can click on that and then when they enter and submit case is created at the back end so I want to remove a couple of the template/grid/request type so I deactivated that from object>fiekds and relationships> deactivate that specific template its showing deactivated still visible in the screen flow. Would appreciate if you can suggest how to fix this error. 

 

 

#Trailhead Challenges

2 answers
  1. Today, 11:16 AM

    @Ashwini Garwandha Thank you for your response just one question to ask here if there are multiple flow versions of the above scenario so manually removing components of the active versions will work right or of all the versions active/inactive/deactivated? 

0/9000

Once I select a picklist field as option A for eg then another picklist field should not appear how can we achieve that. Thanks for your response in advance. 

 

#Trailhead Challenges

2 answers
  1. Today, 11:06 AM

    Will check this functionality though the changes are to be made in the screen flow template. Will let you know if this works. 

     

0/9000

Hi everyone! 

 

I've associated a Data Capture Flow with a Work Plan step, and when running the step from the Field Service mobile app, I get an error message saying, "Only Field Service mobile flow type is supported in the mobile app. Contact your Salesforce admin.". However, when running the same step from the web there's no problem; it runs correctly. 

 

The user has the necessary Field Service permissions to run the step, and even adding administrator permissions, the result remains the same. I've also simplified the flow to the maximum, down to just one assignment, and the same problem occurs. Even so, when associating the same flow with a Work Order record form, it was possible to run it from the mobile app, although, according to the release notes for the latest version, these flows should also be available for work steps (

https://help.salesforce.com/s/articleView?id=release-notes.rn_fieldservice_254_data_capture_flow.htm&release=254&type=5

). 

 

Has anyone encounter the same issue? Am I missing something? 

 

Thank you very much for your help!!

1 answer
  1. Today, 11:05 AM
    I have had same issue. Not sure if it's intended to work... but would be great!
0/9000

I found out that there is an active version of a Process builder, and an active version in Flow Automation, that both do very similar 'things' on the same object. How can I determine which of the 2 is effective? Or is there an implicit priority for the newer technology (Salesforce Flow Automation) ?

4 answers
  1. Today, 11:00 AM

    Given that Process Builder is now end of life, it's a bit of a pointless question. Just deactivate the Process Builder and move the logic into either the existing flow (if possible) or another one. You can use the Flow Trigger Explorer to set the order they execute in if you end up with two flows on one object and need to control the run order.

0/9000

Hello, 

I'm trying to validate the format of a mobile phone in screen flow and not sure why this formula is not doing anything. The flow is saved successfully.  

The Mobile is a text field.  

I used a decision element for now but still would like to know what is wrong with the below. 

Many thanks 

Ewa 

 

validate input in screenflow

 

 

 

#Answers  #Flows

0/9000

Hi everyone, 

We are currently working on developing an offline-capable Lightning Web Component (LWC) that displays related records of Object A on the detail page of Object B. The goal is to ensure that users can view and interact with these related records even when they are not connected to the internet.

Approach 1: Using GraphQL

Initially, I explored using GraphQL to fetch the related records. However, I encountered performance issues when the number of records exceeded 10. The response times became noticeably slower, which is not ideal for an offline experience.

Approach 2: Implementing Cacheable Apex

To address the performance concerns, I transitioned to using a cacheable Apex method. This approach improved performance by leveraging client-side caching, allowing for faster data retrieval. However, I faced a new challenge when attempting to update records using the updateRecords function from Lightning Data Service (LDS).

Issue with updateRecords in Offline Mode

When operating in offline mode, I observed that only 1 or 2 related records were being updated, despite the intention to update all 4 related records. This inconsistency in behavior suggests that the updateRecords function may not be fully compatible with offline scenarios, possibly due to limitations in how LDS handles data synchronization when offline.

Request for Guidance

I am seeking advice on how to effectively implement offline support for updating related records in LWC. Specifically, I would appreciate insights into:

  • Best practices for using LDS's updateRecords function in offline scenarios.
  • Alternative approaches for updating related records offline, such as utilizing the Mobile SDK's entity framework for offline data management.
  • Recommendations for ensuring data consistency and synchronization when transitioning between online and offline states.

Any guidance or resources you can provide would be greatly appreciated. 

Please let me know if codebase files are needed here.   

 

@Irfan Syed, @Adam Liechty, @Amber Craig, @Ashwin Nair, @Saket Agarwal

4 answers
  1. Today, 10:42 AM

    LDS is designed for single-record operations and lacks native support for bulk updates, especially in offline scenarios. The updateRecords function may fail partially due to transaction isolation and cache limitations. Plus, LDS uses a client-side cache that may not reflect real-time changes when offline. Ensure all related records are explicitly included in the offline briefcase for proper priming. 

     

    Use lightning-record-edit-form and the draft-values API to collect and submit offline changes, rather than invoking updateRecords() directly 

    Listen for the online/offline events and call saveRecord() upon reconnect if drafts remain 

     

    Ensure all related records are loaded at least once while online. Consider a hidden wire adapter (@wire(getRelatedListRecords)) on load to hydrate the cache.

    https://developer.salesforce.com/docs/atlas.en-us.mobile_offline.meta/mobile_offline/considerations_wire_adapters_support.htm

     

     

    For mobile SDk use this link:

    https://developer.salesforce.com/docs/platform/mobile-sdk/guide/entity-framework-sync-related.html

0/9000