• Sindhugs
  • NEWBIE
  • 5 Points
  • Member since 2011

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 4
    Replies

Hi,

 

Would anyone be able to let me know the limitations (or location of a document that provides these limits) for the following items?

 

 

  • Record Types
  • Page Layouts
  • Items in a Picklist
  • Formula Fields (I am aware that there is a 500 field limit per object but is there a specific limit for the number of formula fields?)
I'm sure there was a document stating this but I can't find it anywhere...
Cheers
James

 

Hi guys,

 

Here is my situation, I want to query multi-select picklists in static soql, I have done this in dynamic soql, but in static soql, I don't know how to do it?

 

code snippet:

 

String categories = 'Featured, Super Featured';List<Product2> products = [select Category__c from Product2 where Category__c includes (:categories)];

 

In this way, I want to select all the products include Featured or Super Featured category, but I cannot get the right records.

 

But in this way, I got the right records.

 

List<Product2> products = [select Category__c from Product2 where Category__c includes ('Featured','Super Featured')];

Is there anyone can help me this problem? Thanks in advance!!

 

Thanks

 

Message Edited by Eriksson on 03-02-2010 12:50 AM
Message Edited by Eriksson on 03-02-2010 05:03 PM
Message Edited by Eriksson on 03-02-2010 05:04 PM

I've been working on a Visualforce page that displays An account, it's child charitable contributions, and then offers the user the ability to select accounts to recieve charitable donations. The list of accounts is parsed in through the URL. I have the page looking perfect exactly as I'd like (See screen shot below)

 

VF Screen Shot

 

 

The trouble exists when I go to process the selected orders. The selections made on the page do not appear in the class as selected. I confirmed that I can hardcode the list of orders as selected in the class and they will appear checked in the page, but I cannot make the logic work in the other direction. I'm wondering if this has something to do with the nesting of the repeat within a pageblocktable? If anyone has a sense of where I'm making a mistake I'd greatly appreciate it. I can probably solve the problem with javascript, but I'd love to improve my skills with visualforce and apex! I've included the portions of the page and class that I think are relevant, but I can include all the relevant code if there is a piece of the puzzle missing.

 

 

Page Snippet:

<apex:pageBlockTable value="{!Account.Food_Donation_Contributions__r}" var="c" cellpadding="4" id="contributetable">
<apex:column headerValue="Contribution Name" value="{!c.Name}"/>
<apex:column headerValue="Product Type" value="{!c.Product_Type__c}"/>
<apex:column headerValue="Remaining Packs" value="{!c.Total_Remaining_Packs__c}"/>
<apex:column headerValue="Remaining Cases" value="{!c.Total_Remaining_Cases__c}"/>
<apex:column headerValue="Remaining Pallets" value="{!c.Total_Remaining_Pallets__c}"/>
<apex:column headerValue="Choose Recieving Accounts">
<table width="600" border="0">
<tr>
<th align="left">Target Account:</th>
<th align="left">Account Information:</th>
<th align="right">Select</th>
</tr>
<apex:repeat value="{!orders}" var="o">
<apex:outputpanel >
<tr>
<td align="left">{!o.awoname}</td>
<td align="left">Sample Program 1, Sample Program 2, Sample Program 3</td>
<td align="right" width="35"><apex:inputCheckbox value="{!o.selected}"/></td>
</tr>
</apex:outputpanel>
</apex:repeat>
</table>
</apex:column>
</apex:pageBlockTable>
<BR/><BR/><BR/><BR/><BR/>
</apex:pageBlock>
</apex:form>

 

 

Controller Snippet:

 

public pagereference processSelected(){

/*We create a new list of Orders that we be populated only with Ordersif they are selected*/

List<PFD_AWO_Order__c> selectedorders = new List<PFD_AWO_Order__c>();

/*We will cycle through our list of cOrders and will check to see if the
selected property is set to true, if it is we add the Order to the selectedorders list. */
for(cOrder cO : orderList){
if(cO.selected == true){
selectedorders.add(cO.order);
}
}

/* Now we have our list of selected orders and can perform any type of
logic here. In this instance, when active, we will insert the list of orders. */


for(PFD_AWO_Order__c AWOORDER : selectedOrders){
ordermessage = ordermessage + '[Order from'+AWOORDER.PFD_Contribution__c +' for ' +AWOORDER.Animal_Welfare_Org__c+' ]';
}

insert selectedorders;
return null;
}

 

 

Thanks!