• TheBomb
  • NEWBIE
  • 0 Points
  • Member since 2005

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 4
    Questions
  • 6
    Replies
Any help gratefully appreciated -- sorry this got so long.



We're trying to plan our implementation of Sales Force. We want to represent our customers within SF. When representing our customers, we want to recognise that we deal with many customers that are from within a single organisation. For example a head office with multiple offices that are geographically spread. This relationships between our customers in an organisation may be hierarchical, for example:



        Head Office

        /    |      \

      US     EU   ASPAC

     /  \             |      \

    NY  SF        Japan China


We want to represent this hierarchical nature of our customers within SF. From looking at the erd of the standard SF schema, our customers should be represente as Account objects. I have come to this conclusion because the Account object is the only hierarchical object that we can implement in SF. Is this correct? I could implement my own hierarchical object, but I can't create a relationship back to itself.



However, we see that we want to restrict the functionalities of each of the customers in the above hierarchy. For example, we may only want contracts to be associated with US, EU, Japan and China. Is there a way to filter the relationship between objects? I was thinking along the lines of simply filtering the list of available accounts available when selecting which account to relate with an object based on the object type (for example). Is this possible? Am I going down the wrong road?



Lastly, I would like to implement many to many links, say between objects A and B. Presumably the best (only?) way to do this is to implement another object A_has_B? This is not a problem, but when viewing the page for A, I would like to show a list of B objects showing certain information from B other than just it's name. Is this possible? Does anyone have experience of doing this?
I want to pass out the full case ID in a custom URL so that I can refer back to the object through the SOAP interface. However, when I use {!Case_ID} I do not get the full case ID passed in the URL, for example I get passed:

http://...&case_id=50030000001QCG1

yet the same object accessed through SOAP is:

stdClass Object
(
[type] => Case
[CaseNumber] => 00001027
[Id] => 50030000001QCG1AAO
[Status] => New
)

The last three characters do not seem to be regular as I see AAO AAW AAK in the few cases I have in my test database!

How do I get the full case ID passed in the URL? or is there a was to determine these last three characters?
I have written some code to select some custom objects in php from a web page and thought I might use the same code to perform the same operation using cli php...but it doesn't work. For some reason, the query returns a SOAP error message without any message in it! Maybe this is a SOAP issue.

I'm using nusoap/debian/php/linux and a developement sforce application while I am prototyping some functionality.

Sample code is:

require_once("SalesforceClient.php");
$client = new SalesforceClient();
$result = $client->login(XXX,YYY);
if (PEAR::isError($result)) {
$errors = "Error: " . $result->getMessage() . "\n";
} else {
$client = new SalesforceClient($result->sessionId);
$client->_endpoint = $_COOKIE['sf_endpoint'];
$query_str = "select Description, CaseNumber from case ";
$results = $client->query($query_str);
# print_r($result);
if (PEAR::isError($results)) {
print "\n----ERROR\n".$results->getMessage()."\n";
print "$query_str\n\n";
exit;
} else {
foreach ($results as $result) {
print_r($result);
}
}
}
?>
I have a customer object where I want to query for that object through the php SOAP interface by the Name of that object. No objects are returned! If it try where Name like 'ABC%', then it returns a number of objects, including the specific one I'm trying to find.

What am I doing wrong? Am I missing something that is documented about names.

FYI - I'm prototyping some functionality on an sforce development system and the characters ABCD are number (not that this should make any difference). I've installed the SOAP in php as per the included documentation with the example.
This trigger does _not_ save 'Hello!' to the Area__c field on the case, I can't figure out why.  There are no errors.  Here's the log output:

*** Beginning copyFieldsOnCreate on Case trigger event bulk AfterInsert for 500T0000000n9Tf

20070731134615.308:Trigger.copyFieldsOnCreate: line 1, column 1: TriggerBody: copyFieldsOnCreate
20070731134615.308:Trigger.copyFieldsOnCreate: line 2, column 3: SelectLoop:Static: name: Trigger.new, type: LIST:SOBJECT:Case
20070731134615.308:Trigger.copyFieldsOnCreate: line 2, column 31: Block with 3 statements
20070731134615.308:Trigger.copyFieldsOnCreate: line 6, column 5: DeclareVar: Local: name: c, type: SOBJECT:Case with initial value(s): InlineQuery: [select c.id, c.Area__c from Case c where c.Id = :ca.Id]
20070731134615.308:Trigger.copyFieldsOnCreate: line 6, column 14: SOQL query with 1 row finished in 13 ms
20070731134615.308:Trigger.copyFieldsOnCreate: line 6, column 5: initial value: Case:{Id=500T0000000n9TfIAI}
20070731134615.308:Trigger.copyFieldsOnCreate: line 7, column 5: SOBJECT:Case.Area__c assigned Literal: Hello!
20070731134615.308:Trigger.copyFieldsOnCreate: line 8, column 5: Update: SOBJECT:Case
20070731134615.308:Trigger.copyFieldsOnCreate: line 8, column 5: DML Operation executed in 352 ms

Cumulative resource usage:
Number of SOQL queries: 1 out of 20
Number of query rows: 1 out of 1000
Number of DML statements: 1 out of 20
Number of DML rows: 1 out of 100
Number of transaction control statements: 0 out of 0
Number of script statements: 3 out of 10200
Maximum heap size: 0 out of 100000


*** Ending copyFieldsOnCreate on Case trigger event bulk AfterInsert for 500T0000000n9Tf
Can anyone point out my flaw?

Thanks!

I have written some code to select some custom objects in php from a web page and thought I might use the same code to perform the same operation using cli php...but it doesn't work. For some reason, the query returns a SOAP error message without any message in it! Maybe this is a SOAP issue.

I'm using nusoap/debian/php/linux and a developement sforce application while I am prototyping some functionality.

Sample code is:

require_once("SalesforceClient.php");
$client = new SalesforceClient();
$result = $client->login(XXX,YYY);
if (PEAR::isError($result)) {
$errors = "Error: " . $result->getMessage() . "\n";
} else {
$client = new SalesforceClient($result->sessionId);
$client->_endpoint = $_COOKIE['sf_endpoint'];
$query_str = "select Description, CaseNumber from case ";
$results = $client->query($query_str);
# print_r($result);
if (PEAR::isError($results)) {
print "\n----ERROR\n".$results->getMessage()."\n";
print "$query_str\n\n";
exit;
} else {
foreach ($results as $result) {
print_r($result);
}
}
}
?>

Let's say I want to create a custom object called Quote and related list that will appear in the Opportunity tab.  New Quotes will be created via a weblink to a custom web app; that app in turn writes to the Quote object via the API. 

Is it possible to configure something to remove the New button displayed above the related list?  This would enable us to leverage this related list as reference data (like Stage History), but not directly edit data in the custom object from within salesforce.

 

 

  • February 02, 2005
  • Like
  • 0

How can we edit or remove the sub menu under a tab?

In other words, when you click on the leads tab a new menu appears with links to "new Campaign", "new lead", etc, etc

Thanks,

Mark