• Caffeine
  • NEWBIE
  • 150 Points
  • Member since 2009

  • Chatter
    Feed
  • 6
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 20
    Questions
  • 51
    Replies

Hi all,

 

I kind of stuck here. 

 

Problem: I have two tables Account and Website_Profile__c. There are 539 records in the "Website_Profile__c". Since I was not able to use relational queries using PHPToolkit. I was given a reference to the "Website_Profile__c" table in the account table so that I will be able to access the values in the "Website_Profile__c". When I try using the following query,

 

-----------------------------------

 $query = "select Account.Active_Web_Profile__r.Active__c, Account.ID, BillingStreet, Account.Membership_Active_date__c, Account.DBL_Gift_Card__c, Website_Id__c, BillingCity, BillingState, Verified__c, Updated__c, BillingPostalCode, Phone, Account.Name, Account.Website, Industry, Account.Active_Web_Profile__r.Name, Account.Active_Web_Profile__r.ID, Account.Active_Web_Profile__r.History__c, Account.Active_Web_Profile__r.Philosophy__c, Account.Active_Web_Profile__r.Products__c, Account.Active_Web_Profile__r.Account__c, Account.Active_Web_Profile__r.Email__c, Account.Active_Web_Profile__r.Picture__c, Account.Active_Web_Profile__r.Updated__c, Account.Active_Web_Profile__r.Verified__c from Account where Account.Active_Web_Profile__r.Active__c=true ORDER by Account.ID LIMIT 500";

-----------------------------------

 

I get only "250" active records fetched form the Salesforce database instead of "328" active records.

 

Account.Active_Web_Profile__r.Products__c ->  Here the Active_Web_Profile__r is a reference to the "Website_Profile__c" table in the "Account" table which will allows me to access the values from the "Website_Profile__c" table via "Account" table.

 

Why am I not able to fetch all the 328 active profiles?

 

It will be of great help if somebody can tell me where I am going wrong.

 

FYI I am able to access the "328" records from the "Website_Profile__c" table when queried just the single table (Website_Profile__c) and not the relational query.

 

 

Thanks,

Madhan

  • October 27, 2009
  • Like
  • 0

Hi Everyone,

 

First I would like to thank everyone here for all of their help and patience. This is a truly wonderful group and I am very grateful for all of the fabulous programmers who help people like me out when we need it. We would be lost without you!

 

Now - I hope I can impose upon you all for some of your much-needed input...(please):

 

We have created a special field called ERP Cost which is in the product card. We want to use this cost minus the sales price to come up with a margin calculation. This all works very well. The problem is that we want to tally up the margins from each line item in an opportunity and use that to give us a grand total 'Margin' on the opportunity. I am totally stumped on how to create totals by adding up a field on multiple line items.

 

Can anyone help point me in the right direction?

 

Thanks!

I have a custom object with a related list to another custom object.  At the moment the related list is showing all related records.  However, I would like to be able to press a button to see only a subset of the related list items.

 

So, for example, there is a picklist field on the related object called "Type of Plan" which contains 3 possible values.  I would like to be able to have 3 buttons in the related list section that I could press, each of which gives me the related list for value 1, value 2 and value 3.

 

I thought I could add a custom button and some code to do this but cannot figure out how to do it (without resorting to a new VF page...).  A review of forum posts hasn't revealed anything.

 

Any ideas would be greatly appreciated!

 

Regards,

Gordon

 

Hi,

 

I have a workflow set up to auto Close Lost opportunities that are 30 days past their Close Date. 

 

Here's my formula:

and(
      or(

           ispickval( StageName,"Qualified"),

           ispickval(StageName,"Qualified Suspect")),

      TODAY()-CloseDate=30, 
      ispickval(Type ,"Renewal Business"))

 

I have an opportunity that meets all these criteria and the workflow has not fired.  Any thoughts? 

I would like to delete records using a external key.

But the delete operation from the APEX DATALOADER won't let me use the external key as key for deletion!

 

So, what is the way to delete records via an external key?

 

 

Message Edited by Streepeye on 03-31-2009 06:22 AM

I got a question from a guy from a customer  today about My Domain, SP-Initiated SAML and the Admin login

Background:
- When setting up 'My Domain' and Federated, you can set up SP-initiated AND set it so that all logins must be from the My Domain page (no going to login.salesforce.com)
- Now consider this scenario, they set up SP-initiated and also check the flag to lock logins to be only from the My Domains page.  Their IDP goes down.  The Admin tries to login.  It seems he is stuck.  He goes to the My Domain page, which forwards him to the IdP which is down.  He can't go to login.salesforce.com because of the lock setting.
Question: What do they do?
I believe the only answer is that they cannot lock people to using the My Domains page without risking locking the Admin out in the case of an IDP-down situatino. They have to leave open the possibility of going to login.salesforce.com to allow the Sys Admin to login in an emergency situation.
Thoughts?
 

I have the following formula field on the Account object. (We have Person-Accounts enabled)

 

IF( PersonHasOptedOutOfFax, Fax & " " &   IMAGE($Setup.LTSS__c.Opt_Out_Image__c, "Do Not Contact",  15,15), Fax)

 

And salesforce gives me: Error: Field PersonHasOptedOutOfFax does not exist.

 

Problem is that when I look at the Account object in the Force.com IDE, it certainly does have a PersonHasOptedOutOfFax field (and it is filterable meaning that it is queryable.

 

What gives?

I'm trying to write a program that pulls data from SFDC, processes it and then pushes data back.  I wanted to use the Bulk API to do the pushes back, but have been stumped by a strange problem:

 

1. Using the Partner WSDL, the first part of the program where the data is pulled from SFDC and processed works fine.

 

2. I created a totally separate Java project to do the Bulk API piece using the wsc-18.jar and partner-18.jar from the Bulk API Google site.

 

3. I built the Bulk piece totally separately.

 

4. I put the compiled custom Bulk jar into my first project.

 

5.  After that, the original project starts spewing errors like this:

 

ERROR main org.apache.axis.client.Call - Exception:
norg.xml.sax.SAXException: Invalid element in com.sforce.soap.partner.sobject.SObject - Id
        at org.apache.axis.encoding.ser.BeanDeserializer.onStartChild(BeanDeserializer.java:258)
        at org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1035)
        at org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
        at org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
        at org.apache.axis.message.RPCElement.deserialize(RPCElement.java:236)
        at org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)
        at org.apache.axis.client.Call.invoke(Call.java:2467)
        at org.apache.axis.client.Call.invoke(Call.java:2366)
        at org.apache.axis.client.Call.invoke(Call.java:1812)
        at com.sforce.soap.partner.SoapBindingStub.query(SoapBindingStub.java:3274)

ERROR main org.apache.axis.client.Call - Exception:norg.xml.sax.SAXException: Invalid element in com.sforce.soap.partner.sobject.SObject - Id        at org.apache.axis.encoding.ser.BeanDeserializer.onStartChild(BeanDeserializer.java:258)        at org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1035)        at org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)        at org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)        at org.apache.axis.message.RPCElement.deserialize(RPCElement.java:236)        at org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)        at org.apache.axis.client.Call.invoke(Call.java:2467)        at org.apache.axis.client.Call.invoke(Call.java:2366)        at org.apache.axis.client.Call.invoke(Call.java:1812)        at com.sforce.soap.partner.SoapBindingStub.query(SoapBindingStub.java:3274)

 

 

The original project is using version 18 or the Partner WSDL and, from my reading, the above error is seen frequently when you try to send an Enterprise WSDL request to a Partner end-point or vice-versa, but that's not the case here.

 

Any ideas?

 

Thanks.

I've written some very simple Java code to query the the ContentVersion object.

 

If I don't include the VersionData field everything works fine.  If I include the VersionData field, I get the following low-level error:

 

Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 1
n      at com.sforce.soap.partner.QueryResult.getRecords(QueryResult.java:94)
        at net.xxx.salesforce.content.ContentSynch.listContent(ContentSynch.java:176)
        at net.xxx.salesforce.content.ContentSynch.run(ContentSynch.java:91)
        at net.xxx.salesforce.content.ContentSynch.main(ContentSynch.java:68)

 

It's actually failing in code generated from the Partner WSDL:

public com.sforce.soap.partner.sobject.SObject getRecords(int i) {
        return this.records[i];
    }

 

 I'm going against a Trial Org with 2 Powerpoint presentations. 

 

Any ideas on what might be going wrong?  Again, if I remove the VersionData field everything is fine.

 

 

Code:

-----------------------------------------------------

//Note: for some reason API fails when you try to query Language, RecordTypeId
    String soql = "Select " +
        "Id," +
        "ContentDocumentId, " +
        "ContentModifiedById," +
        "ContentModifiedDate," +
        "ContentSize," +
        "ContentUrl," +
        "CreatedById," +
        "Description," +
        "FeaturedContentBoost," +
        "FeaturedContentDate," +
        "FileType," +
        "FirstPublishLocationId," +
        "IsLatest," +
        "NegativeRatingCount," +
        "OwnerId," +
        "PathOnClient," +
        "PositiveRatingCount," +
        "PublishStatus," +
        "RatingCount," +
        "ReasonForChange," +
        "TagCsv," +
        "Title," +
        "VersionData," +
        "VersionNumber " +
        "from ContentVersion";

    logger.debug("Query: " + soql);
    try {
        qr = _binding.query(soql);

        logger.debug("Records returned: " + qr.getSize());
    }
    catch (RemoteException ex) {
        logger.error("Content Query failed: " + ex.getMessage());
        System.exit(-1);
    }
    return qr;
}

 

void listContent(QueryResult qr) {
        //loop through until all records have been retrieved
        boolean done = false;
        while(!done) {
            for(int i = 0; i < qr.getSize(); i++)  {
                logger.debug("i is " + i);
                logger.debug("qr.getSize() is " + qr.getSize());
                logger.debug(qr.getRecords(i).getId());  //BOOM!
            }
            if (qr.isDone()) {
                done = true;
            }
            else {
                try {
                    qr = _binding.queryMore(qr.getQueryLocator());
                }
                catch (RemoteException ex) {
                    logger.error(ex.getMessage());
                }
            }
        }

}

I know there are some Java/Axis gurus in salesforce, so I'm hoping one might answer the following:  how does one add a SOAP Header when using code generated by WSDL2Java?

 

Here are the details:

I'm trying to consume an authentication web service.  The WSDL specifies that the username and password are passed in the SOAP header.  Here is the relevant section of the WSDL:

<operation name="Logon">
      <soap:operation soapAction="http://MerrillLynch.Framework.Security/Logon" style="document" />
      <input>
        <soap:body use="literal" />
        <soap:header d5p1:required="true" message="s0:LogonAuthHeader" part="AuthHeader" use="literal" xmlns:d5p1="http://schemas.xmlsoap.org/wsdl/" />
      </input>
      <output>
        <soap:body use="literal" />
      </output>
    </operation>

 

But in the Java code generated by WSDL2Java, I'm not seeing how add this SOAP header using the methods provided.    I've done the usual Googling, but there is nothing that I can that tells how to do it in a straightforward manner.

 

Does anyone know the trick?

 

Thanks.

 

 

All,

We’re doing some Apex Callout work and getting an odd error that I cannot find any documentation on.

 

We’re doing a 2-way SSL callout (req.setClientCertificate(‘cert’,’pwd’) and getting back this:

ERROR - Evaluation error: System.CalloutException: Script-thrown exception

 

More info:

·         We know the external service is up and running. 

·         We have a non-SSL version of the service and it connects fine without the cert.

·         It’s only when use the cert & key that the error occurs.

·         We’ve set all the debug flags but can’t seem to milk any more information out of it.

 

Code and debug is attached if anyone wants to take a look.

 

We've set the Debug Log level to CALLOUT to try to get information, but it's not returning anything useful at all.

 

Thanks.

--Debug Log--below..see last couple of statements:

13:11:08 ERROR - Evaluation error: System.CalloutException: Script-thrown exception

13:11:08 ERROR - Evaluation error: Class.ZZZ_TEST.buildHttpRequest: line 47, column 23 AnonymousBlock: line 1, column 1

 

There is conflicting information out about the SOQL return limit for Batch Apex.

 

The Apex Docs say the limit is 5 Million.

 

This SFDC blog post says the limit is 50 Million. 

http://blog.sforce.com/sforce/2009/05/batch-apex-a-powerful-new-functionality-in-summer-09.html

 

Which is right?

 

 

I got a question from a customer today and just wanted to verify the answer with the community.

 

If I send an HTTP Callout to a web service that a customer has exposed, how do I make sure that it is compressed?  If I simply add an  HTTP header like: Content-Encoding: gzip  will that do it?

 

 

We're trying to set two-way SSL and the customer asked if the salesforce.com client cert ever expired.  Fair question, but I'm not sure of the answer.  Does anyone know?

 

Thanks. 

Working for a VLO and we are trying to set up a process to use integration to change the User's Default Division based on a feed from an external system. 

 

When you change a User's Default Division in the web client, a screen comes up and asks you whether you want to change the Division for all of the records that the user owns.  Is there any way to duplicate this programmatically?  Or would we have to actually query for all of the records that the user owns and change the Division for all objects that the user owns?

 

Thanks.

In the Metadata API documentation, the retrieve() example code pulls down the requested content in a zip file (which is great), but is there a way to use retrieve() and get the metadata unzipped?

 

I'm working on a Metadata tool and I want to just pull down the content and access the files the directly.

 

(I know I can unzip the files programmatically in Java, but was hoping there was a way to skip this step).

 

Thanks,

C

I'm doing a RunAllTests and am getting the following:

Exception in Account_AsynchProcessing TriggerFuture method cannot be called from a future method: formatSObjectData(String, LIST:String)

 

I'm not sure what the Exception is saying.  Here is the setup:

-  A trigger has a statement that calls a @future method in a global class.  The future method itself does not make calls to other future methods.

 

Is it invalid to call @future methods from a trigger?

 

Thanks.

 

 

 

It's possible I'm missing something, but it doesn't seem like the 'Log Level' indicator is having any effect on what is shown in the log section of the 'Apex Test Runner'. 

 

Here's what I'm doing: 

1. Hit the 'clear' button

2. Set log category to: Apex Code

3. Set log level to: Error

 

 

But there's much more than errors coming back in the log window.  Every debug still shows up.  Is there something I'm missing?

 

Thanks.

I've tried following the instructions here:

http://wiki.developerforce.com/index.php/Force.com_Code_Share

 

Here is what I have done:

1. I've got the code from Code Share

2. It shows up as a project in my Force.com IDE perspective

 

How do I get this code into my developer org, though?

 

I have added my Developer Org credentials to the project and done all of the "Sychronize" steps, but the project files just aren't showing up in my Developer Org.  (I can edit and save the files and everything looks like it is going well), the files just don't show up.

 

Any hints?

 

Thanks.

SOQL that compares against the value null gives indeterminate results.

Example:

select Id, PublicGroupId__c from WorkGroup__c where Id = 'a0OR00000002v1x' and PublicGroupId__c != null    

Result=> returns no records (The PublicGroupId__c field does has a value)


select Id, PublicGroupId__c from WorkGroup__c where Id = 'a0OR00000002v1x' and PublicGroupId__c = null      

Result=> returns no records!


select Id, PublicGroupId__c from WorkGroup__c where Id = 'a0OR00000002v1x' and PublicGroupId__c != ' '

Result=> returns 1 record!


But if we query for another nearly identical object like this:

select Id, PublicGroupId__c from WorkGroup__c where Id = ' a0OR00000002xqp ' and PublicGroupId__c != null

Result=> returns 1  record!!!   (The PublicGroupId__c field does have a value)


select Id, PublicGroupId__c from WorkGroup__c where Id = ' a0OR00000002xqp ' and PublicGroupId__c  = null

Result => returns no  records


Does anyone know something about this SOQL ‘feature’?

Are Partner (as in the Partner object) records deleted for good and not sent to the Recycle bin?

 

Here's the behavior: 

1. I add a Partner to an Account.  

I immediately query and see the the two Partner records (one for each direction)

 

2. I delete the Partner from the Account.

I queryAll (adding IsDeleted=true) to the filter and the Partner records aren't returned

 

Is there something special about Partner records (or other Many-to-Many types) that causes them to be deleted without being recoverable/queryable from the Recycle bin?

 

Thanks,

C.

Hello all,

I'm working on a project to give users the ability to create secure notes on any object.  The design is going fine except for the last piece: how to encrypt or obfuscate the note so that even administrators browsing cannot read them.

 

Apex does not do encryption (only hashing), so I have to come up with a method for obfuscating the note.  

 

I can do this with JavaScript, but how do I:

1. Obfuscate some text in JavaScript and then save it back to a salesforce field?

 

A secondary question, is there any other way anyone can think of to do this other than javascript?

 

Thanks,

C.

All,

I'm trying to lookup all of the RecordTypes available to a Profile for an Object.  I checked the API guide and the ProfileRecordType object looks like the perfect fit.  Only problem is that it doesn't appear to be visible from the API.  I tried both API 14.0 and 15.0, but an error message comes back saying that it's not supported.

 

Two questions:

1. Should I be able to see this object?

2. If not, how can I find out which RecordTypes a certain profile has access to?

 

Thanks,

C.

Sandbox was upgraded to 158 and now the Force.com IDE spits out the following when you try to pull in a project from the upgraded Sandbox:

 

"This package was deleted in your production organization and is no longer accessible from this Sandbox organization"

 

Any clues on what the root cause might be or a fix/workaround?

 

 

Thanks.

I've tried the following code in 2 different orgs and it doesn't work:

<apex:page standardController="Account">
 <apex:pageBlock title="My Title">
     <b>Hello {!$User.FirstName}</b>
 </apex:pageBlock>   
  <apex:detail rendered="true"/>
</apex:page>


The "Hello username" works just fine, but the detail part of the page never shows.

I've even stripped it down to basics:

<apex:page standardController="Account">
   <apex:detail rendered="true"/>
</apex:page>

Nothing appears in this case.  The example is taken nearly verbatim from the VF Developer Guide.  What gives?

Thanks.

Hi:

 

I would like to know what is the best possible approach to migrate data from production to sandbox on a regular basis. Once we refresh sandbox with production metadata the application data gets erased, we have a real challenge to bring the data back to sandbox with a specified timeframe.

 

Our Sandbox is not a full sandbox.

 

Regards,

Arup

I am new to Salesforce, trying to connect salesforce through JAVA but getting below error.

I have got this sample code from Salesforce documentation on API.

http://www.salesforce.com/us/developer/docs/api/index_Left.htm#StartTopic=Content/sforce_api_partner.htm

 

Did anyone face this issue before? Please help me to resolve this error.

 

 

Enter username: xxxxxxxxxxxxxxxxxxxx
Enter password: xxxxxxxxxxxx

LOGGING IN NOW....
An unexpected error has occurred: ; nested exception is:
 java.net.ConnectException: Connection timed out: connect
AxisFault
 faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
 faultSubcode:
 faultString: java.net.ConnectException: Connection timed out: connect
 faultActor:
 faultNode:
 faultDetail:
 {http://xml.apache.org/axis/}stackTrace:java.net.ConnectException: Connection timed out: connect
 at java.net.PlainSocketImpl.socketConnect(Native Method)
 at java.net.PlainSocketImpl.doConnect(Unknown Source)
 at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
 at java.net.PlainSocketImpl.connect(Unknown Source)
 at java.net.SocksSocketImpl.connect(Unknown Source)
 at java.net.Socket.connect(Unknown Source)
 at com.sun.net.ssl.internal.ssl.SSLSocketImpl.connect(Unknown Source)
 at com.sun.net.ssl.internal.ssl.SSLSocketImpl.&lt;init&gt;(Unknown Source)
 at com.sun.net.ssl.internal.ssl.SSLSocketFactoryImpl.createSocket(Unknown Source)
 at org.apache.axis.components.net.JSSESocketFactory.create(JSSESocketFactory.java:92)
 at org.apache.axis.transport.http.HTTPSender.getSocket(HTTPSender.java:191)
 at org.apache.axis.transport.http.HTTPSender.writeToSocket(HTTPSender.java:404)
 at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:138)
 at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
 at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
 at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
 at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
 at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
 at org.apache.axis.client.Call.invoke(Call.java:2767)
 at org.apache.axis.client.Call.invoke(Call.java:2443)
 at org.apache.axis.client.Call.invoke(Call.java:2366)
 at org.apache.axis.client.Call.invoke(Call.java:1812)
 at com.sforce.soap.enterprise.SoapBindingStub.login(SoapBindingStub.java:3750)
 at com.doc.samples.Samples.login(Samples.java:78)
 at com.doc.samples.Samples.run(Samples.java:318)
 at com.doc.samples.Samples.main(Samples.java:35)

 

Thanks,

I've written some very simple Java code to query the the ContentVersion object.

 

If I don't include the VersionData field everything works fine.  If I include the VersionData field, I get the following low-level error:

 

Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 1
n      at com.sforce.soap.partner.QueryResult.getRecords(QueryResult.java:94)
        at net.xxx.salesforce.content.ContentSynch.listContent(ContentSynch.java:176)
        at net.xxx.salesforce.content.ContentSynch.run(ContentSynch.java:91)
        at net.xxx.salesforce.content.ContentSynch.main(ContentSynch.java:68)

 

It's actually failing in code generated from the Partner WSDL:

public com.sforce.soap.partner.sobject.SObject getRecords(int i) {
        return this.records[i];
    }

 

 I'm going against a Trial Org with 2 Powerpoint presentations. 

 

Any ideas on what might be going wrong?  Again, if I remove the VersionData field everything is fine.

 

 

Code:

-----------------------------------------------------

//Note: for some reason API fails when you try to query Language, RecordTypeId
    String soql = "Select " +
        "Id," +
        "ContentDocumentId, " +
        "ContentModifiedById," +
        "ContentModifiedDate," +
        "ContentSize," +
        "ContentUrl," +
        "CreatedById," +
        "Description," +
        "FeaturedContentBoost," +
        "FeaturedContentDate," +
        "FileType," +
        "FirstPublishLocationId," +
        "IsLatest," +
        "NegativeRatingCount," +
        "OwnerId," +
        "PathOnClient," +
        "PositiveRatingCount," +
        "PublishStatus," +
        "RatingCount," +
        "ReasonForChange," +
        "TagCsv," +
        "Title," +
        "VersionData," +
        "VersionNumber " +
        "from ContentVersion";

    logger.debug("Query: " + soql);
    try {
        qr = _binding.query(soql);

        logger.debug("Records returned: " + qr.getSize());
    }
    catch (RemoteException ex) {
        logger.error("Content Query failed: " + ex.getMessage());
        System.exit(-1);
    }
    return qr;
}

 

void listContent(QueryResult qr) {
        //loop through until all records have been retrieved
        boolean done = false;
        while(!done) {
            for(int i = 0; i < qr.getSize(); i++)  {
                logger.debug("i is " + i);
                logger.debug("qr.getSize() is " + qr.getSize());
                logger.debug(qr.getRecords(i).getId());  //BOOM!
            }
            if (qr.isDone()) {
                done = true;
            }
            else {
                try {
                    qr = _binding.queryMore(qr.getQueryLocator());
                }
                catch (RemoteException ex) {
                    logger.error(ex.getMessage());
                }
            }
        }

}

Hello,

 

I am a java developer. After i login to salesforce, i need a custom way to set the profile settings i.e, intercept the login request and set the individual permissions(in the profile object) manually. Is there any way i can achieve this funtionality ? Please provide your inputs/suggestions.

 

Best Regards

Hello All,

 

As new Scontrol is no longer supported in development.

Is there any risk to use of connection.js and  apex.js in visualforce pages?

 

Just want an expert thought and discussion on this.

 

 

Thanks

 

I know there are some Java/Axis gurus in salesforce, so I'm hoping one might answer the following:  how does one add a SOAP Header when using code generated by WSDL2Java?

 

Here are the details:

I'm trying to consume an authentication web service.  The WSDL specifies that the username and password are passed in the SOAP header.  Here is the relevant section of the WSDL:

<operation name="Logon">
      <soap:operation soapAction="http://MerrillLynch.Framework.Security/Logon" style="document" />
      <input>
        <soap:body use="literal" />
        <soap:header d5p1:required="true" message="s0:LogonAuthHeader" part="AuthHeader" use="literal" xmlns:d5p1="http://schemas.xmlsoap.org/wsdl/" />
      </input>
      <output>
        <soap:body use="literal" />
      </output>
    </operation>

 

But in the Java code generated by WSDL2Java, I'm not seeing how add this SOAP header using the methods provided.    I've done the usual Googling, but there is nothing that I can that tells how to do it in a straightforward manner.

 

Does anyone know the trick?

 

Thanks.

 

 

Hi all,

 

I kind of stuck here. 

 

Problem: I have two tables Account and Website_Profile__c. There are 539 records in the "Website_Profile__c". Since I was not able to use relational queries using PHPToolkit. I was given a reference to the "Website_Profile__c" table in the account table so that I will be able to access the values in the "Website_Profile__c". When I try using the following query,

 

-----------------------------------

 $query = "select Account.Active_Web_Profile__r.Active__c, Account.ID, BillingStreet, Account.Membership_Active_date__c, Account.DBL_Gift_Card__c, Website_Id__c, BillingCity, BillingState, Verified__c, Updated__c, BillingPostalCode, Phone, Account.Name, Account.Website, Industry, Account.Active_Web_Profile__r.Name, Account.Active_Web_Profile__r.ID, Account.Active_Web_Profile__r.History__c, Account.Active_Web_Profile__r.Philosophy__c, Account.Active_Web_Profile__r.Products__c, Account.Active_Web_Profile__r.Account__c, Account.Active_Web_Profile__r.Email__c, Account.Active_Web_Profile__r.Picture__c, Account.Active_Web_Profile__r.Updated__c, Account.Active_Web_Profile__r.Verified__c from Account where Account.Active_Web_Profile__r.Active__c=true ORDER by Account.ID LIMIT 500";

-----------------------------------

 

I get only "250" active records fetched form the Salesforce database instead of "328" active records.

 

Account.Active_Web_Profile__r.Products__c ->  Here the Active_Web_Profile__r is a reference to the "Website_Profile__c" table in the "Account" table which will allows me to access the values from the "Website_Profile__c" table via "Account" table.

 

Why am I not able to fetch all the 328 active profiles?

 

It will be of great help if somebody can tell me where I am going wrong.

 

FYI I am able to access the "328" records from the "Website_Profile__c" table when queried just the single table (Website_Profile__c) and not the relational query.

 

 

Thanks,

Madhan

  • October 27, 2009
  • Like
  • 0

Dear All,

 

If the user’s profile has the "Single sign-On Enabled" permission in organization level, Can that user work on the workflow process?

 

If yes, How the user name and approver name will be mapped with salesforce user object?

 

Thanks in advance.

 

--KSR 

  • October 27, 2009
  • Like
  • 0

I like to include a link to my salesforce record in an outbound  Messaging.SingleEmailMessage email, but I don't want to include a hard code instance as outlined in the documentation. How do I get the salesforce instance na1, na2, na3,... that I am working on. Pagereference getURL() only returns a partial URL.

 

From the documentation:

 

 http://www.salesforce.com/us/developer/docs/apexcode/index_Left.htm#StartTopic=Content%2Fapex_classes_email_outbound.htm|SkinName=webhelp

 

mail.setHtmlBody('Your case:<b> ' + case.Id +' </b>has been created<p>'+
' View case <a href=https://na1.salesforce.com/'+case.Id+'>click here</a>');

 

Thanks,

 

Matt

I want to run program at a specific time.please give me a demo.thank you!
  • September 04, 2009
  • Like
  • 0

I got a question from a customer today and just wanted to verify the answer with the community.

 

If I send an HTTP Callout to a web service that a customer has exposed, how do I make sure that it is compressed?  If I simply add an  HTTP header like: Content-Encoding: gzip  will that do it?

 

 

I manage account sharing using APEX (accountshare table). If that user is specified in the lookup (Account manager) he is given access to that account(and related contact and opportunities). But, the problem is when the account is part of a tree. Likethis

                       A

                                    |

______________

|            |                

B C

_____________

| | |

D E

 

So if a user is specified in the manager lookup in account E, I need to make sure he has full access to the entire tree:A.B.C.D.E.F. I have seen that giving the user access to A does not give him access to accounts lower down in the heirarchy automatically.

 

Any ideas? 

 

Hi Everyone,

 

First I would like to thank everyone here for all of their help and patience. This is a truly wonderful group and I am very grateful for all of the fabulous programmers who help people like me out when we need it. We would be lost without you!

 

Now - I hope I can impose upon you all for some of your much-needed input...(please):

 

We have created a special field called ERP Cost which is in the product card. We want to use this cost minus the sales price to come up with a margin calculation. This all works very well. The problem is that we want to tally up the margins from each line item in an opportunity and use that to give us a grand total 'Margin' on the opportunity. I am totally stumped on how to create totals by adding up a field on multiple line items.

 

Can anyone help point me in the right direction?

 

Thanks!

Hi, I would really like to add a logo to my application so the user knows that we offer salesforce integration.  I was thinking of using salesforce.com's favicon.

 

I am not sure if this is legal though, has anyone else investigated this branding issue?  Is there a way to get permission or approval, or do I just have to make my own?

I am trying to access the salesforce production environment using the eclipse plugin. I can do this with the sandbox but it doesn't appear to recognise my login credentials when I try to go into production. I can login fine via the web but in the logs for my user it says "Invalid Password" next to my login attempt. My password was not wrong and neither was my security token. What is going on here?
I am trying to create a Date of Birth field. Whether you are using a VF page or a regular page layout, when you use the calendar in Salesforce, it only lets you pick from years going forward. So the calendar is useless for something like a Date of Birth since obviously the year is before this year. Obviously the user can type the date, but is there any other way to adjust how the calendar behaves.

Hi All,

I want a input text in my visualforce page. On clicking this inputbox the standard salesforce calendar should popup. Is this possible.

Please note that i need only a input text and not a input field.

I got the below code from the forums.

What are the values that i have to pass in the highlighted part of the code. Is this possible in Visualforce.

Code:
<a href="javascript&colon;openPopupFocus

('/home/calendar.jsp—form=form1&field=sdate&mo=0&callonchange=true', '_blank', 186, 170, 'width=186,height=170,resizable=yes,toolbar=no,status=no,scrollbars=no,menubar=no,directories=no,location=no,dependant=yes', true, true);"

class="datePicker"

title="Pick A Date (New Window)"

onclick="setLastMousePosition(event)"

id="sdatePopCal">

<img src="/s.gif" alt="Pick A Date (New Window)" class="datePickerIcon">

</a>

 Thanks,
Edwin