Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

The tag has no usage guidance.

0
votes
1answer
24 views

Invalid conversion from runtime type ERROR

I'm trying to parse json response.. but keep getting this error Invalid conversion from runtime type List ANY> to Map String,ANY> Map<String, Object> MapLv3 = new Map<String, Object>()...
0
votes
1answer
14 views

Cant get the 1st row from JSON Parsing array

Im trying to get the participants data from API response.. //Level 1 Map<String, Object> MapLv1 = (Map<String, Object>) JSON.deserializeUntyped(parser); ...
1
vote
1answer
39 views

Parsing Using JSON2Apex

Im trying to use the JSON2Apex to get the parsing class for my API response.. I only need the metrics data for each userId, but I cant get the variable and the system always giving error Variable ...
1
vote
1answer
14 views

Method does not exist or incorrect signature: void parse(String) from the type or_propertyJSONTest

I am new to apex callouts and trying to do some JSON parsing. I used the online tool https://www.adminbooster.com/tool/json2apex which worked great. I got a class and a testclass from the ...
0
votes
2answers
38 views

Help Parsing JSON Body

Im trying to get the Id and Name from JSON Body that I requested, and put the value into custom object { "id": "ab24ddb8-f1ef-4cca-ae72-9f20f5975332", <-- THIS "name": "App Dev Account", <-- ...
0
votes
1answer
57 views

Best way of generating a random number

In order to get fake IDs for testing needs I wrote something that works and is reusable, but I'd like to know if there is better ways because my code seems heavy. n is the total caracters of the ...
0
votes
1answer
87 views

System.JSONException: Unexpected character ('1' (code 49)): was expecting comma to separate OBJECT entries

"sourceMessage": "<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?><error code=\"VALIDATION_FAILED\"> <failure cause=\"INVALID_VALUE\" field=\"Status\" value=\"NotDefined\...
0
votes
1answer
98 views

Is there a limitation of date value while parsing in apex

There seems to be some parsing limitation on string dates in apex. When I am doing the following it throws a system exception saying invalid date: String s = '12/31/5000'; Date.parse(s); However ...
-1
votes
1answer
53 views

How do i deserailize this json string

Can Any one help me in deserializing this json string: "(ActivityHistory:{AccountId=0011a00000qWdtzAAC, Id=00T1a00001m4m99EAA, WhoId=0031a00000u3iXlAAI, Subject=Call, Status=Completed, Priority=...
0
votes
2answers
212 views

Handle Extra “\r\n” new line in CSV from code level

I'm using the following code to Parse CSV file in Apex: public static List<List<String>> parseCSV(String contents,Boolean skipHeaders) { List<List<String>> allFields = new ...
0
votes
3answers
89 views

How to parse a hal+JSON response that has a invalid node name

In general I know how to create a apex class to parse the JSON response in salesforce. But with the current system I am integrating has a weird node name format and i having issues with creating apex ...
0
votes
0answers
28 views

Parsing ERROR Ending position out of bounds: 255

Need some help with parsing csv thru apex . Below are the records i am trying to pass in csv but i am seeing an error : Ending position out of bounds: 255 1,,,"ABC,DEF",,"Robert, Thoma; (CFD)", ,Me ...
1
vote
2answers
93 views

Convert HTTP Response date to Apex Datetime

I have an HttpResponse object with the Date as a header property. Its format looks like this: Thu, 13 Jul 2017 06:59:43 GMT and I would like to parse it as an Apex Datetime object. I did multiple ...
1
vote
0answers
42 views

Taking the email body information from an Email-To-Case

We are currently using Email to Case for one of our customers and they send us in their data straight out of their system i am guessing using a template, They have the data in the same format and i ...
1
vote
1answer
107 views

Deserialising JSON with a '.' variable

I am attempting to deserialise a JSON response with some variables that Salesforce is having a problem handling because there is a '.' in the object name (as well as a '.' in some variable names). ...
1
vote
0answers
151 views

Parsing Google Sheets JSON response

I am working on a project where I need to access values in a Google Sheet, scan them for certain keywords, and if they meet a particular condition, copy the data from a given row into an object in ...
0
votes
0answers
115 views

Selectively Parsing a JSON file

I am attempting to parse MatterMark's API, but I am planning to do so selectively, picking only the value pairs that are relevant. The example JSON response is available to be viewed in MatterMark's ...
3
votes
1answer
323 views

Pass Case Ids collection to visual workflow from Case List View Custom Button and update cases taking from input screen

Requirement From Case list View, user will choose one or more cases and will click on "Update Due Date" button, where it will show a screen to choose the "Due Date". Due Date screen And finally ...
1
vote
0answers
27 views

Apex Generation Failed (WSDL parsing error) [duplicate]

I'm trying to parse a simple Webservice and I'm receiving this error: Apex Generation Failed: Unable to find complexType for {http://soap.***}RelationshipReferenceTo There are two lines in ...
3
votes
1answer
326 views

WSDL error in parsing process

I have been trying to parse a WDSL file in FuseIt and also in SFDC, but I get an error that it is not allowing me to generate the apex classes I need. This the error I get in SFDC: Apex ...
2
votes
2answers
57 views

Strategy On Restructuring SOQL Query

I hope someone can lend some advice on how to go about this issue. I believe it to be more of a strategy question. After my code as been written and tested, we found a new field that was needed to ...
1
vote
2answers
109 views

Test Error: JSON2Apex method does not exist

Error: Method does not exist or incorrect signature: JSON2Apex.parse(String) I used https://json2apex.herokuapp.com/. I got back APEX and a test class that should work. I am getting the above ...
2
votes
1answer
2k views

What is wrong with this query? (Unknown error parsing query)

When I run the following query in query editor I get this error. Error Unknown error parsing query Query SELECT Id, OwnerId,Account.OwnerId FROM Contact where OwnerId = Account.OwnerId limit 100 ...
0
votes
2answers
583 views

REST JSON response to VF page

I'm trying to parse the json string into meaningful data over a VF page. Here's where I'm stuck... public class callApi{ private final String serviceEndpoint= 'http://XXX'; public String Response {...
3
votes
2answers
654 views

Map one xml to List of SObject?

I am quite new in Xml parsing. i am having a XMl <company> <account> <id>8c98a6be</id> <label>4356</label> <reference>4356</reference> </...
6
votes
2answers
93 views

Corpus Analysis for Salesforce?

I am asking this question here instead of Stack Overflow because I believe it has relevance to other Salesforce developers. If I am mistaken and this post starts racking up close votes, I will move it ...
2
votes
1answer
2k views

Illegal Value for primitive when trying to parse the json data

I am facing the issue like "Illegal Value for primitive" when trying to parse the json data.Below is the Json Response which i get from a service. [{"revenue": {}, "emails": [{"grade": "A+", "type": "...