Skip to main content
New
Stack Overflow Jobs powered by Indeed: A job site that puts thousands of tech jobs at your fingertips (U.S. only). Search jobs

Questions tagged [csv]

A comma-separated values (CSV) file stores tabular data (numbers and text) in plain-text form.

Filter by
Sorted by
Tagged with
0 votes
1 answer
31 views

List view button on 'Products' (aka OLIs) related list in opportunity

I have an ask to add a button on the opportunitylineItem related list of the opportunity where that button will download all olis into a csv. I have hit 2 issues that i'll describe: I simply haven't ...
Langloic's user avatar
0 votes
1 answer
39 views

CSV report generation using apex batch

I am trying to generate the csv report by fetching the data from ApexTestResult obj. But the column 'message' in the apextestresult obj is overlapping and automatically divided the message and showing ...
RKCY's user avatar
  • 323
0 votes
2 answers
118 views

Read CSV with more than 10K lines and 36 columns

I need to efficiently read a large CSV file with approximately 10,000 lines and 36 columns. However, I'm encountering a 'regex too complex' error with my current implementation. Could you please ...
Chirag's user avatar
  • 11
0 votes
1 answer
68 views

Variable Does Not Exist Error for a Nested Query in Apex

I am getting this error with this class. Variable does not exist for Subject, ActivityDate, ActivitySubType, and Status. public class ExportActivityHistory { public static void ...
SFIDK's user avatar
  • 1
0 votes
0 answers
74 views

Generating csv file from LWC in a managed package

I have a LWC with a button to download a list of records in a CSV file. My code is: const exportedFilename = 'issues.csv'; if(navigator.msSaveBlob){ navigator.msSaveBlob(...
Fran Mejias's user avatar
0 votes
0 answers
171 views

Bulk API 2.0: Can I insert AND upsert in one csv request?

Edited to clarify: Background info on what I'm working on – we're going to be receiving email lists from clients, and we want to create new Leads or update existing Leads in Salesforce with the info ...
Brittany Layne Rapheal's user avatar
1 vote
5 answers
2k views

Can't read CSV file using data Loader 59

I tried all three suggestions from another question asked in this community "Data loader CSV Error: Can't read from CSV file" and none of those answers solved my problem. I just loaded Data ...
Catherine Moskowitz's user avatar
0 votes
1 answer
146 views

Salesforce API SOQL - Exporting data as CSV [duplicate]

Is it possible via Salesforce SOQL API to get the results in CSV rather than JSON? Example of the call I am making (via Postman for testing) GET /services/data/v51.0/query?q=SELECT id,name,profile....
Ron Swanson's user avatar
0 votes
0 answers
164 views

CMDT CSV Insert Problems

Am trying to insert new records for a custom metadata file and saw that force:cmdt:record:insert has been deprecated. I tried sf cmdt generate records --csv path/to/my.csv --type-name MyCmdt but VS ...
Dmns's user avatar
  • 21
3 votes
1 answer
2k views

How to calculate how much storage a CSV will use when uploaded to SObject

So I have a .csv file that contains ~12,000 rows and on my local filesystem takes up about 3MB of data. I assumed that when I imported this csv into a Salesforce Object, the data would still take up ...
Tyler Edwards's user avatar
1 vote
1 answer
645 views

PapaParse in LWC after Winter '23 heightened security?

I am trying to use PapaParse (a Javascript CSV analyzer library) in a Lightning Web Component. A lightning modal hosts the tool. Although I have seen examples of doing so in the past, I have been ...
skycafe's user avatar
  • 397
0 votes
1 answer
868 views

How to save a csv file to folder

I needed to do generate a csv file and save it to salesforce folder every day at 08:00 AM. So i did the generating a csv file every day at 08:00 AM with: public class TrucksExport implements ...
Marjan's user avatar
  • 3
0 votes
0 answers
21 views

How to parse CSV file containing line breaks within the CSV cells using Apex [duplicate]

I have a CSV file uploaded in Salesforce Document, That CSV contains line breaks within the cell. So when I try to parse this CSV file with "csvFileContent.split('\n')", I am expecting all ...
Jagadeesh's user avatar
0 votes
1 answer
367 views

Can I convert a JSON property (not full JSON) to csv with DataWeave without parsing it first to an Apex class?

It's been very easy with DataWeave in Apex to convert a JSON to a csv. However, I'm getting a JSON from a REST call, and the part I'm interested in is located in the "data" property, ...
Fabien Taillon's user avatar
-1 votes
1 answer
120 views

Nested Json response to csv conversion

I got this response from API however I couldn't be able to parse name because of the nested objects, example this is my query trying fetch permissionSetAssignment records from one org to other in ...
Praveen Patil's user avatar
1 vote
0 answers
222 views

Apex - PageReference - Report URL

When our org was in classic, we had the below code which used to save a report as an Attachment. This has worked for the past 7 years... PageReference reportLink = new PageReference('/'+reportId+'?...
Neil Brown's user avatar
3 votes
1 answer
1k views

Escape Comma in Column While Creating CSV in LWC

I need to escape comma in Column values while Creating CSV file in LWC. I tried with replacing comma with Keywords but still when converting string into blob it splits value with comma. I'm sending ...
Kartik jadhav's user avatar
0 votes
2 answers
190 views

how to take single field value when use the ',' in field value in csv file

for(sObject sObj : scope) { AggregateResult ar = (AggregateResult)sObj; Integer IdCount = (Integer)ar.get('cnt'); String accName = (String)ar.get('accName'); ...
sunny roxx's user avatar
0 votes
1 answer
779 views

Can you chunk a csv file by passing the parsed file to a Batch Class?

I have a class that is parsing a csv file but running into heap limits. To resolve that I am converting it into a batchable class. However the List of lists is not getting accepted. I am getting the ...
Pauline's user avatar
  • 375
0 votes
1 answer
27 views

Modify string value in soql list and add back to list

I have a VFP which functions as a CSV download. In my controller I return a simple SOQL list from a custom Customer object. I need to modify the Name being returned to remove all commas and then add ...
Wes's user avatar
  • 41
-1 votes
1 answer
951 views

Converting CSV to an APEX List [closed]

I have a csv file downloaded with 1 column listing about 3000 names. What is the simplest way to grab all these names and store them in a List to be further manipulated in Apex? Thanks!
Austin Kelly's user avatar
1 vote
1 answer
936 views

How to process papa parse results in apex class

Folks, I want to parse CSV files with papa parse in apex. I have a lwc to upload the file and a custom apex class to massage the data and insert results to custom object. My question is what do I ...
SavvyGoat's user avatar
  • 105
-2 votes
1 answer
4k views

Generate CSV , EXCEL file dynamique with lightning web component

I have a problem with my code , I want to generate a file ( CSV / XLS ) , but with my code I get nothing , I don't now what is the problem . Some help please . <a target="_self" class=&...
salesforcedev's user avatar
0 votes
1 answer
133 views

Creating records from csv is running twice

I wrote a lightning component that reads a csv file and creating records with relationship, e.g opportunities and their related contacts in each row. some of the contacts already exists in org ...
DavidS's user avatar
  • 37
0 votes
1 answer
735 views

RecordTypeId not getting uploaded from csv file to Salesforce org using SFDMU tool. Error: Value does not exist or does not match filter criteria

I am using SFDMU tool (Salesforce Data Loader SFDX Plugin) to upload csv data files to a target salesforce org. I have 3 records A, B and C in an object in a hierarchy. Record B is in a self-lookup ...
Ritika_salesforce's user avatar
-2 votes
1 answer
261 views

Dataloader Insert Problem

I'm trying to insert an Excel data in my org via Dataloader. But, when i try to use INSERT with the .csv file, i can't find the 'State__r:State__c:Code__c' in the mapping field. Error> State: id ...
Felipe Simoni's user avatar
0 votes
1 answer
2k views

How to create a test class for apex that reads CSV file

I was trying to test my apex class that gets a CSV file, reads it and creates actual records. In my test class I tried to convert my CSV string into base64 string. Then I used this line of code Blob ...
Xrhstos Kolonis's user avatar
0 votes
1 answer
785 views

SSJS Automation Studio - Read imported CSV file

I'm new to SSJS and Automation Studio. What I'm trying to achieve is a simple automation based on the CSV File Drop - File Drop -> Script After a CSV file was dropped into a specified location, ...
Kosmetika's user avatar
  • 103
0 votes
1 answer
844 views

How to split csv string

I am using dataloader and retrieve data like that: "0017Q000003T1EdQAK","sForce ""Test"" ","Some,data","","94087","" ...
Vupsen''s user avatar
0 votes
0 answers
113 views

Is it possible to import IsMasterLanguage field from CSV file in UI import articles feature in salesforce lightning?

Hi guys I am trying to import salesforce knowledge articles from CSV file however I am getting an error that displays IsMasterLanguage column in the header cannot be mapped. So I wanted to know ...
Muhammed Rishdhi's user avatar
0 votes
1 answer
760 views

Download Records in to csv file [closed]

I have created a to Download contacts in to csv filw. retrieved the data needed. There is a problem in converting to csv. I have tried everything. Below is my code. ERROR is: Cannot read properties ...
Dilip Reddy's user avatar
0 votes
1 answer
1k views

Insert record from static resource csv

I have csv file with account records and want to insert that records via apex. How can i do it and dynamically find necessary fields? I can only manually assign them and its hard to parse cause of ...
Tirkocuyda's user avatar
0 votes
2 answers
5k views

Export data and download file

I am exporting some data into csv from org and want to download that file. Now i can just send it to email. Any ideas? List<Account > acclist = [Select id,name , CreatedDate , lastModifiedDate ...
Terdivi's user avatar
  • 51
0 votes
1 answer
508 views

How to remove all unicode characters from a blob?

I have a requirement to parse the contents of a csv blob which has unicode characters. When I am trying to parse it using Blob myBlob = EncodingUtil.base64Decode(response.getBody()) I am getting an ...
Knight of the Vale's user avatar
0 votes
1 answer
4k views

How to parse a CSV file into JSON using APEX?

I am getting a CSV file as a Blob in response to one of the callouts. I need to parse this CSV file and convert the contents into a flat JSON structure. Is there an inbuilt way to parse CSV in apex ? ...
Knight of the Vale's user avatar
0 votes
2 answers
3k views

'Field Not Found' and 'Required Field' Error Importing CSV to Data Extension

I just tried importing a .CSV file to a Data Extension (there are only 3 rows as I'm doing a test), but I keep getting an error. My CSV files have the right headers that can be mapped, so I'm not sure ...
Kenneth T.'s user avatar
1 vote
1 answer
608 views

Is there a way to upload/insert a particular custom object record and its related file document from one single csv file using data loader?

Hi it would be great if anyone could help me out with this. I have encountered a requirement in salesforce where I have to upload/insert a custom object record and its related file attachment into ...
Muhammed Rishdhi's user avatar
0 votes
1 answer
29 views

CSV file adding default row by using excel

As you can see in the image below I'm trying to open a CSV file by using Excel but every time I tried there is a row that I don't need excel add it by default, how can I remove this option I don't ...
MaylaSFMC's user avatar
1 vote
1 answer
3k views

Read a csv file that is stored in Attachment Object

I have an excel/csv as an attachment related to an EmailMessage. I want to read the csv, process the data and create certain records(of custom object) based on that data. I want to understand how I ...
Awais Ahamed's user avatar
0 votes
0 answers
159 views

Test.loadData is not inserting data for Producer object

I am working on a Data Factory test class and I was able to successfully load relational data for Account, Case, WorkOrder, User, InsurancePolicy and couple of other custom objects by providing Id in ...
SunnyG's user avatar
  • 421
0 votes
1 answer
159 views

How to import two values that are in the same excel field separated by a comma

I just got an .csv file that i need to import into my sandbox as a custom object, it looks like this: The value that is on the left side of the comma should be stored as a field (called Location). ...
Mr Hamburguers's user avatar
0 votes
1 answer
620 views

E-Mail with csv attachment processed in Salesforce [closed]

It is possible to send an email with an attachment to salesforce and that this attachment will be processed there? The attachment contain multiple columns and rows for update or create records.
peXeq's user avatar
  • 471
1 vote
1 answer
1k views

How to force ANSI Encoding on a generated CSV attachement in apex?

I want to generate a csv attachement and force ANSI encoding how can i do that? Code to create my attachement: string rows = 'column1;column2;column3'+'\n'+'a;b;c' Attachment attachment = new ...
collin's user avatar
  • 83
0 votes
2 answers
1k views

Handle double quotes in a long text field when generating a CSV file from apex

I have a custom object in which I have a long text area field. I am querying it in apex and building a CSV and sending an email with csv as attachment. The value in the long text area field and which ...
Sisir's user avatar
  • 111
2 votes
2 answers
3k views

Parsing large CSV file in LWC

I have implemented the following code to parse a csv file, convert to a JSON array and send the JSON result to apex controller, which invokes the batch class to process the DML operation for ...
sakthidasan's user avatar
0 votes
3 answers
453 views

CPU Limit Exceeded Visualforce Page Controller

I am running into a CPU limit error when processing more than + or - 300 rows from a .csv file, via a Visualforce page/controller. I realize CPU limits can have a lot to do with other items running ...
Jklotzle's user avatar
2 votes
1 answer
882 views

Comparing string in CSV header against expected value yields not equal when debug log shows they are identical

I'm reading a CSV file saved in a ContentVersion The CSV header looks like: FirstName,LastName,... I'm checking to make sure the first line (header row) matches the expected column headers using this ...
cropredy's user avatar
  • 71.7k
1 vote
0 answers
1k views

Value provided is invalid for action parameter 'fileContent' of type 'Blob'

So, I'm trying to pass a csv file to apex, with a lightning input type file and a button with an onclick that calls to the apex method, receiving a blob variable: @AuraEnabled public static String ...
joacoiudica's user avatar
0 votes
1 answer
752 views

Create CSV from SOQL query

I'm trying to download the results from my SOQL query as a CSV, but when I choose "Bulk CSV" the resulting file contains the query itself and not the result set. List view shows 21k+ ...
Andrew's user avatar
  • 3
1 vote
1 answer
249 views

Searching CSV Data stored in Long Text Field

I am new to Salesforce and wanted to get some guidance on building a solution for the following use case. I am currently working on a Salesforce project building a hotel reservation system for service ...
SalesforceNovice's user avatar

1
2 3 4 5 6