The tag has no wiki summary.

learn more… | top users | synonyms

3
votes
0answers
17 views

How can we keep our tasks accessible to view and report on while not having them count against the data storage limit?

The org I am working with right now is using 210% of its allotted data storage. Most of the storage space is taken up by tasks (over 31M records). Is there a way to decrease the data usage while ...
1
vote
3answers
35 views

Custom Save on New/Edit page - Is this valid code?

In my controller extension I have a custom save method that works for New and Edit scenarios also saves modified child records The below code works in all unit tests but starts to show strange ...
2
votes
1answer
118 views

Is upsert the right thing to save new or existing records?

In many of my Controller extensions I have save action methods that work for NEW and EDIT scenarios. I simply use upsert record instead of update / insert record in such cases. But now I am running ...
1
vote
1answer
15 views

'<<<' characters are lost in a field after saving to the database?

I have a field on a custom object before saving to the database as below: <span>>>> just some text <a class="Link" href="/55555555555AAA" >John Travolta</a> ...
4
votes
1answer
52 views

Database class commit

Why does Database class not provide commit method so that we can commit explicitly as well while in a transaction as we can do a rollback.
0
votes
2answers
42 views

Old style JOIN (ANSI JOINs) syntax is not allowed. Please use standard syntax

A client has asked me to write a rather complex SQL query to be used on Salesforce. When trying to implement the finished query on the Queries page I get the following error: Old style JOIN (ANSI ...
0
votes
1answer
50 views

Is there a way to create a master-detail to the Campaign Member object

TLDR; Is there a way to build a joint object between the campaign member and account objects? If not, what are some other methods to design the SFDC database to capture the specific individuals that ...
2
votes
1answer
83 views

Storing json as a String field is giving wrong value

I have been developing an Apex Trigger where I build a json string from an incomming Event. What I do is serialize the event into the json at first, then deserialize it as a Map and add to it some ...
0
votes
1answer
39 views

Database.rollback() risks and alternative

I've inherited some complex logic that does several different DML actions within the same (fairly long) method and if there are failures I need to revert everything that's been previously done. The ...
2
votes
1answer
66 views

Can Salesforce function as a “data warehouse?”

I am attempting to integrate on-premises software with our Salesforce Org. Our timekeeping system uses a PostgreSQL database to store time entries committed by staff. Salesforce's role is relegated to ...
6
votes
1answer
149 views

Can I tell how many records in a Database.QueryLocator()?

According to the documentation, in a batch a Database.QueryLocator can retrieve up to 50 million records. A maximum of 50 million records can be returned in the Database.QueryLocator object. If ...
0
votes
1answer
28 views

Inserted records have lifespan only within current Visualforce page

I have a VF page which dynamically inserts records into a custom object. To debug the problem and ensure the records have been successfully, I reloaded the inserted records after the insertion. The ...
1
vote
2answers
268 views

Problem with Database.update()

I have some accounts to update but some validation rules can failed. So to avoid this I use the Database.update() function to update accounts even if some DML exception occur. try { ...
0
votes
0answers
15 views

How to connect salesforce to external database without any third party tool [duplicate]

How to connect salesforce with SQL Server database without any third party tool like data loader or informatica. Is it possible to connect via Apex web services. It could be soap/wsdl based, or basic ...
1
vote
1answer
56 views

Database.DeleteResult.getErrors() question

I am trying to connect specific records that fail to delete in my batch job to their error messages. I thought my solution was working, but I checked the size of .getErrors() and it's size 1. My test ...
11
votes
1answer
232 views

How can adding a Subselect make a SOQL query non-selective?

I have a SOQL Query with subquery that fails to execute because it is non-selective. I don't understand why and cannot interpret the results. All I know is that tearing parent und sub query apart ...
7
votes
1answer
147 views

Database.DMLOptions - How to prevent Chatter Group Auto-Follow trigger from generating email

Currently I have a trigger which auto-follows specific groups in our organization when a new user is brought onboard. The auto-follow trigger feature works great! However, we have quite a few groups ...
2
votes
3answers
102 views

Backing up sf data in external DB [closed]

Hi I need to back up my sf org data into my local database. I am looking out for tools or any best practices to this at specific time intervals or regular time intervals. Can any one suggest what ...
3
votes
1answer
192 views

Salesforce database structure for sales cloud and service cloud

Do any one here have any doc related to database model of salesforce. Model of sales cloud and service cloud. I go through doc which salesforce have ...
3
votes
1answer
48 views

External SalesForce Forms

Is it possible to create external SalesForce Forms that can populate fields in the same way as inside salesforce? We offer online teaching and the idea is that teachers, after every lesson, can fill ...
1
vote
2answers
67 views

Tally the number of items in a related lists on a related object

Hi guys I am a complete n00b with SalesForce.com, so please forgive me if my question is too basic, but I have been trying for about 2 days now and I feel like I am getting nowhere I have a database ...
2
votes
2answers
150 views

Salesforce Mirrored To mySQL - Reporting Tool Suggestions?

We are setting up mirroring our Salesforce to mySQL using CopyStorm. One object in particular will be mirrored with no deletion (all data ever will accumulate in mySQL while in Salesforce it will ...
0
votes
1answer
838 views

Database schema export

Hi we have a date export made from salesforce instance. We'd like to rebuild just the database but we stumbled on process to import the CSV files to a SQL Server database. We have force.com IDE ...
1
vote
2answers
216 views

Data replication from MS SQL to Salesforce

I'm trying to setup our MSSQL server to "replicate" new insert/updates to Salesforce, but it appears that there is no official way to do it via Salesforce. Is there a recommended way? Background: I'm ...
1
vote
1answer
633 views

Pass a String in Select query - SOQL

I have a String that contains some custom fields of Account. I want to pass a String in a Select query like this : String myString = 'myCustomField1__c, myCustomField2__c'; List<Account> ...
1
vote
0answers
154 views

Guidelines for Salesforce Database (Objects) design

What are the best practices for Salesforce Database structure (Object structures)? . It is very difficult to query data from a highly normalized structure. As in we cannot follow the RDBMS (Oralce Db, ...
1
vote
2answers
212 views

Get ID with upsert

I'm trying to insert/update a custom object in database with upsert but after the upsert I need to get the database ID. Is there a way to get the new/updated ID on database without querying the ...
0
votes
1answer
246 views

Database Save Results, Map.values() and maintaining order

Maybe because it is Friday afternoon, but I feel like I am missing something obvious here. I am trying to work out how I can refer back the errors from a database.insert to the key in my map. So I ...
2
votes
0answers
69 views

sObject insert execution not synchronous

I have a custom object and a controller action that creates a new record of this type. The action then returns a page where the list of objects are displayed. save() { ... insert myObject; ...
3
votes
3answers
546 views

Can I rollback a Before Insert trigger from an after trigger event?

Scenario: After an object is inserted/updated (can happen after any of the two) - I update an external system with that object's info - Object ID is needed - which is why I need the After Insert. ...
1
vote
1answer
185 views

Database.delete and CRUD permissions

I have an detail Custom Object that has Contact as its master. My user profile has Read, but not Edit, Delete or Create permission. When I login as this user I can View the record, but the Edit and ...
2
votes
0answers
207 views

Is there a simple way to generate a create table script from a salesforce class?

I am looking for a way to synchronize Salesforce data with a local database. At the moment I just want a pain free way of downloading the data. I've been playing around with importing CSVs from the ...
0
votes
1answer
209 views

How to recognize duplicate records and other criteria within a Data Extension

Currently the AMPscript based landing page features an indication that shows how many individuals are signed up for an event. This number is arrived at simply by ROWCOUNT to see how many fields in the ...
5
votes
6answers
746 views

Most efficient (instant / no Batch) way to mark thousands of records as dirty

I have the requirement to store and retrieve the information that a set of arbitrary sobject records are "dirty" and need to be touch by asynch processes. I am talking about 10.000 to 100.000 records ...
0
votes
1answer
139 views

Accessing field dependancy values in the back end

On our UI we have two picklist fields where we provided field dependancy. On the front end we can see these dependancies. Now at the backend there will be a table to store these values. I would like ...
2
votes
0answers
104 views

Newbie : Save User Credentials in Salesforce [closed]

I am making an App which has to run in Salesforce and eventually distributed over Appexchange. In my app, I would like the Salesforce user to enter his Username and Password (with which he registered ...
5
votes
2answers
2k views

where do I use Database. Methods?

I m trying to understand where we use following Database.Methods. I know if we want to insert a record to an object we use DML Statement. What i want to know is why/where we use Database. methods. It ...
9
votes
2answers
214 views

How can updated SObjects/CObject be queried/retrieved without duplicate or missing records?

Another way to ask the question: Are SOQL queries transactional/atomic on the second level? I am writing a data integration with salesforce using the REST API. I want to retrieve a list of updated ...
1
vote
0answers
106 views

Temporary Restore of Salesforce

I always get asked the question by my clients - "What happens if we can't access Salesforce?". "Take regular backups" we say. But is that enough? Has anyone attempted to restore their Salesforce ...
38
votes
3answers
703 views

Any reason to skip DML on empty lists?

In parts of my code I have DML statements with an if around to only do the DML if the list is not empty: if( !recordsToUpdate.isEmpty() ) { update recordsToUpdate; } Couldn't I just write? ...
1
vote
2answers
2k views

Salesforce API for saving data in Salesforce database using any other language (Cakephp)

Friends, I am a web developer(Cakephp). I am working on the XYZ project. In that project I have many Contact forms example - contact us form, user details form, enrollment form etc. I developed that ...
11
votes
2answers
1k views

Can I prevent an insert to be rolled back even if my class (later) runs into an exception?

I do some custom logging in my code which basically means I write and update sobject records that contain custom log information. The problem is whenever an exception is thrown in my class the ...
0
votes
1answer
180 views

Using Database.DeleteResult in custom code

How can I use Database.DeleteResult for custom functionality. I'd like to be able to construct it, set and get its fields.
7
votes
1answer
452 views

Why does the documentation stipulate that a many-to-many object relationship requires two master-detail relationships?

In theory you can model a many-to-many relationship using lookup fields exclusively or in combination with a master-detail field. However the documentation only mentions master-detail fields. What ...
4
votes
2answers
124 views

Values of formula fields using NOW() and TODAY() actually stored in the database?

Just for the sake of argument, if I had the following formula field: MyObject__c.FormulaField__c = DAY(TODAY()) What is the actual value of this field stored in the database, will the value ...
8
votes
2answers
3k views

Is manual Database.setSavepoint() and rollback needed on Trigger exception?

When something wents wrong in my synchronous trigger do I have to manually take care of this by before making a Database.setSavepoint() and rollback in the catch statement? Or is Salesforce.com ...
2
votes
0answers
97 views

Obtaining users data after accepting / allowing a Chatter Application

I'm slowly on the road to completing my PHP application, the final piece to my knowledge is figuring out how, after a user accepts the use of an Application (I think I'm using a remote app atm), to ...
3
votes
1answer
505 views

Which free/commercial Salesforce To SQL app should I use? [closed]

I am looking for an easy to use app to synchronize (one-way) Salesforce data to a SQL database. I don't need mapping functionality that products like Jitterbit, Boomi and Informatica offer for a lot ...
0
votes
1answer
555 views

What the best way to store data from Javascript in “salesforce”

I'm writing a small analytics app in Javascript and want to store data in a database. Since I am new to salesforce I can't figure out the best way to do this: a normal DB such as heroku (postgresql) ...
-1
votes
2answers
1k views

How to define self relationship in salesforce

I am newbie to salesforce.Can some one explain how can i create self relationship in salesforce. I know salesforce doesn't provide out of the box this relationship. My Scenario is i have a Company ...