• FuguSailor
  • NEWBIE
  • 75 Points
  • Member since 2013

  • Chatter
    Feed
  • 3
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 6
    Questions
  • 10
    Replies

I have a VisualForce page that I'm attempting to expose as a site. When I create the SOQL query for data from the page within SalesForce, I can get data for a contact record. When the site is used to access the data, I do not recieve data if I filter based on the contact name. Same exact query performed as a SalesForce page and as the SalesForce site but when it runs as a site, I don't recieve data.

 

I've added the contact record type to the site's profile settings. The permission to the Contact record is set to read only.

 

Is there a log somewhere that I can look at for the site that might give me an idea what the issue is?

 

Thanks in advance.

When my apex code processes the following query:

 

SELECT Name, Requirement_Name__c, Sprint__r.Sprint_Name__c, Stake_Holder__r.Name, Priority__c, Status__c FROM Requirements__c  WHERE  Status__c NOT IN ('Cancelled','Released') ORDER BY Name

 

I do not receive values for the Stake_Holder__r.Name nor the Sprint__r.Sprint_Name__c reference fields. The Stake_Holder__c field holds the Id for a Contact object and the Sprint__c field holds a reference to a Sprint__c custom object. The proper values are shown in the configuration pages for the Requeirements__c records but when the query runs in my controller, there aren't any values shown. This happens both in the developer console and when viewing as a site. If I try to run the query in the developer console, it seems to hang the page. Using the Apex IDE, it executes but I only get the type name of the root referenced object.

 

Any ideas?

 

Thanks in advance.

Sorry. It has been a long time since I did a lot of web developement. I used to use AJAX to get partial matches for user entry as they typed.

 

I could use some help with the terminology and maybe sample for something giving the same behavior as the search box in the SalesForce home page where it shows matching, recent searches.

 

Thanks in advance.

 

Sorry I'm sure there are already treads on this but without the proper terminology, I come up with results that aren't quite what I'm looking for.

I'd like to test SOSL to get familiar with what I can do with it but when I put a query in the developer console, it doesn't seem to pass the parsing rules. How do I test SOSL queries before I build them in my Apex code?

In standard SQL I used to create self joins to find duplicate entries where you would have a field like Name, that should be unique, but because there is a composite key, but one of the values is not correct. Doing this I could write an SQL query that would be something like:

 

SELECT T1.NAME, T1.FIELD_1, T2.NAME, T2.FIELD_1

FROM MYTABLE AS T1, MYDABLE AS T2

WHERE T1.NAME = T2.NAME AND T1.FIELD_1 <> T2.FIELD_2

 

How would I do this in SOQL?

I'm writing some test code to cover someone else's code and I'm having an issue where the code checks the values in a reference class. The code has a Case class with some custom fields and one of these fields is a reference to a master Case object. I build both case objects, assign the Id of the master object to the child and in the test method, the values all look good. The problem is that when the code gets into the production code, the reference fields are not getting resolved. I do an upsert of all of the instances in the test code before calling the code to be tested.

 

I've come to understand that there is blocking of selecting live data in test code so I'm wondering if that is what is causing the reference fields to not be resolved.

 

This makes it so that the best I can get on code coverage is 66% and would like to get much better but because many of the required values are null, a good share of the code does not get executed.

 

Thanks in advance for your help.

I have a VisualForce page that I'm attempting to expose as a site. When I create the SOQL query for data from the page within SalesForce, I can get data for a contact record. When the site is used to access the data, I do not recieve data if I filter based on the contact name. Same exact query performed as a SalesForce page and as the SalesForce site but when it runs as a site, I don't recieve data.

 

I've added the contact record type to the site's profile settings. The permission to the Contact record is set to read only.

 

Is there a log somewhere that I can look at for the site that might give me an idea what the issue is?

 

Thanks in advance.

When my apex code processes the following query:

 

SELECT Name, Requirement_Name__c, Sprint__r.Sprint_Name__c, Stake_Holder__r.Name, Priority__c, Status__c FROM Requirements__c  WHERE  Status__c NOT IN ('Cancelled','Released') ORDER BY Name

 

I do not receive values for the Stake_Holder__r.Name nor the Sprint__r.Sprint_Name__c reference fields. The Stake_Holder__c field holds the Id for a Contact object and the Sprint__c field holds a reference to a Sprint__c custom object. The proper values are shown in the configuration pages for the Requeirements__c records but when the query runs in my controller, there aren't any values shown. This happens both in the developer console and when viewing as a site. If I try to run the query in the developer console, it seems to hang the page. Using the Apex IDE, it executes but I only get the type name of the root referenced object.

 

Any ideas?

 

Thanks in advance.

Sorry. It has been a long time since I did a lot of web developement. I used to use AJAX to get partial matches for user entry as they typed.

 

I could use some help with the terminology and maybe sample for something giving the same behavior as the search box in the SalesForce home page where it shows matching, recent searches.

 

Thanks in advance.

 

Sorry I'm sure there are already treads on this but without the proper terminology, I come up with results that aren't quite what I'm looking for.

I'd like to test SOSL to get familiar with what I can do with it but when I put a query in the developer console, it doesn't seem to pass the parsing rules. How do I test SOSL queries before I build them in my Apex code?

In standard SQL I used to create self joins to find duplicate entries where you would have a field like Name, that should be unique, but because there is a composite key, but one of the values is not correct. Doing this I could write an SQL query that would be something like:

 

SELECT T1.NAME, T1.FIELD_1, T2.NAME, T2.FIELD_1

FROM MYTABLE AS T1, MYDABLE AS T2

WHERE T1.NAME = T2.NAME AND T1.FIELD_1 <> T2.FIELD_2

 

How would I do this in SOQL?

I'm writing some test code to cover someone else's code and I'm having an issue where the code checks the values in a reference class. The code has a Case class with some custom fields and one of these fields is a reference to a master Case object. I build both case objects, assign the Id of the master object to the child and in the test method, the values all look good. The problem is that when the code gets into the production code, the reference fields are not getting resolved. I do an upsert of all of the instances in the test code before calling the code to be tested.

 

I've come to understand that there is blocking of selecting live data in test code so I'm wondering if that is what is causing the reference fields to not be resolved.

 

This makes it so that the best I can get on code coverage is 66% and would like to get much better but because many of the required values are null, a good share of the code does not get executed.

 

Thanks in advance for your help.