function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Ramesh KallooriRamesh Kalloori 

How to upload custom object data from csv or xls using apex code?

Best Answer chosen by Ramesh Kalloori
Ramesh KallooriRamesh Kalloori
Thanks All,

I have done loading data from csv through apex. Find the below link for reference.

http://www.forcetree.com/2010/08/read-and-insert-records-from-csv-file.html

All Answers

Vinit_KumarVinit_Kumar
What is the use case here why do u want upload CSV using Apex.

Why cant we use Dataloader for this purpose ??
Ramesh KallooriRamesh Kalloori
Dataloader is a software it need to be download but i want to load data through apex code.

is there any option?
CRMandresGCRMandresG
If you are looking to automate a dataload we use a cloud integration tool called Cast Iron that picks up flat files from a directory and loads it into salesforce.
OyeCodeOyeCode
Explain, why you need that ?
Ramesh KallooriRamesh Kalloori
Thanks All,

I have done loading data from csv through apex. Find the below link for reference.

http://www.forcetree.com/2010/08/read-and-insert-records-from-csv-file.html
This was selected as the best answer