Crazyma5102 / dataloadercliq

Automatically exported from code.google.com/p/dataloadercliq
0 stars 0 forks source link

External ID problem on Upsert #37

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Hi!,

I'm using this tool to schedule upserts to Salesforce.

I found exactly the same problem as described in Issue 17 
(http://code.google.com/p/dataloadercliq/issues/detail?id=17) , but with 
Products. Seems that the solution given doesn't work. As output I get the same 
error as reproduced but with TTL_ID__c instead.

Can you explain your fix?, and, if it's possible a solution for this.

Thanks,

MGA

Original issue reported on code.google.com by spavilad...@gmail.com on 18 Oct 2011 at 10:52

GoogleCodeExporter commented 8 years ago
What is your external id field on Products?  TTL_ID__c is the field from the 
other user - yours will be different.
Which version of CLIq are you using?  The 2.0 version GUI will check your 
external ID for you.

Vijay

Original comment by vijay.swamidass@gmail.com on 18 Oct 2011 at 5:03

GoogleCodeExporter commented 8 years ago
Hi Vijay,

I don't have any external id field on Products. I'm using CLIq version 2.0.

MGA.

Original comment by spavilad...@gmail.com on 19 Oct 2011 at 6:15

GoogleCodeExporter commented 8 years ago
Ok - The issue 17 is about configuring upserts with an External ID.

What are you trying to accomplish?

Original comment by vijay.swamidass@gmail.com on 19 Oct 2011 at 6:26

GoogleCodeExporter commented 8 years ago
I'm trying to schedule an upsert of object Products.

Original comment by spavilad...@gmail.com on 19 Oct 2011 at 6:43

GoogleCodeExporter commented 8 years ago
If you want I can copy the exception to take a look at it.

Original comment by spavilad...@gmail.com on 19 Oct 2011 at 6:45

GoogleCodeExporter commented 8 years ago
Yes, please send the exception.

Original comment by vijay.swamidass@gmail.com on 19 Oct 2011 at 6:47

GoogleCodeExporter commented 8 years ago
Here you have

Original comment by spavilad...@gmail.com on 19 Oct 2011 at 6:50

Attachments:

GoogleCodeExporter commented 8 years ago
What is in your process-conf.xml?  You can remove the username/password.

Original comment by vijay.swamidass@gmail.com on 19 Oct 2011 at 7:01

GoogleCodeExporter commented 8 years ago
Here is the process-conf.xml

Original comment by spavilad...@gmail.com on 19 Oct 2011 at 7:31

Attachments:

GoogleCodeExporter commented 8 years ago
If you don't have any external id field, this line will not help and will cause 
the error:
<entry key="sfdc.externalIdField" value="TTL_ID__c"/>

Remove that.

If you have no external id, you need to provide an "Id" field in your upload 
file.  If the "Id" doesn't match anything in the object, it will create a new 
record.

Original comment by vijay.swamidass@gmail.com on 19 Oct 2011 at 7:45

GoogleCodeExporter commented 8 years ago
But if I put this was because the system gave me the same error as described in 
Issue 17

Original comment by spavilad...@gmail.com on 19 Oct 2011 at 7:48

GoogleCodeExporter commented 8 years ago
This is de log without the line in process-conf.xml mentioned above.

Original comment by spavilad...@gmail.com on 19 Oct 2011 at 7:51

Attachments:

GoogleCodeExporter commented 8 years ago
http://www.salesforce.com/us/developer/docs/api/Content/sforce_api_calls_upsert.
htm

See that doc for details about upsert. You have to specify either a Salesforce 
Id or an external id.
Most people use an external id because they are bringing the data from another 
system.

Original comment by vijay.swamidass@gmail.com on 19 Oct 2011 at 8:17

GoogleCodeExporter commented 8 years ago
Hi,

Ok, thanks for the doc. I didn't knew about that property of the upsert calls. 
Then I have a slightly different problem. I need to Upsert a CSV that contains 
the Products object to the same system where was taken (which means that the 
file has exactly the same fields as the object in Salesforce).  

Maybe this is not the proper place to ask about this and I should be asking in 
the Developer Forums, sorry about that.

After reading the doc and what you tell me in the comment above seems that I 
need to specify the Salesforce Id as external ID. Which, i think means that the 
field 'Id' itself would be the external ID. Am I right?.

Thanks,

MGA.

Original comment by spavilad...@gmail.com on 19 Oct 2011 at 9:24

GoogleCodeExporter commented 8 years ago
If you are putting the data in the same system where it was taken, then you can 
get the record id.  If you always have the id, then you want to do an "update" 
not an "upsert" operation.

Also, take a look at the data loader document. The link is on the home page of 
this site.

Original comment by vijay.swamidass@gmail.com on 19 Oct 2011 at 4:08

GoogleCodeExporter commented 8 years ago
Hi again,

After reading and understanding the documentation of the Upsert function and de 
Data Uploader, I placed the required External ID field on my Org, I also added 
the line 

<entry key="sfdc.externalIdField" value="External_Record_ID__c"/>

with the logical name of the External ID field that I've created. I also 
assured that the file contains the same column and all the values are correct. 
But after fire the upsert the process log gives me an error for each record I 
want to upsert, the error is this one:

2011-10-20 11:48:54,983 ERROR [JenssenProductsUpsert] client.PartnerClient 
processResult (PartnerClient.java:402) - Errors were found on item0
2011-10-20 11:48:54,983 ERROR [JenssenProductsUpsert] client.PartnerClient 
processResult (PartnerClient.java:404) - Error code is:MISSING_ARGUMENT

Any idea of what should I do in order to upsert properly records to the org?

Many thanks for all the help given until now, you are being very helpful!.

MGA.

Original comment by spavilad...@gmail.com on 20 Oct 2011 at 11:58

GoogleCodeExporter commented 8 years ago
Hi,

I already solved my problem. The problem was in the mapping, I forgot to add 
the External ID to the mapping file. 

Many thanks for all the guidance and help on this,

Great tool, keep strong developing it!

MGA. 

Original comment by spavilad...@gmail.com on 20 Oct 2011 at 12:28

GoogleCodeExporter commented 8 years ago
Thanks - Good to hear it is working now!

Original comment by vijay.swamidass@gmail.com on 20 Oct 2011 at 5:04