Tips and Tricks Tips and Tricks
eBook: $16.99
Formats: PDF, PacktLib, ePub and Mobi formats
save 20%!
Print + free eBook + free PacktLib access to the book: $51.98    Print cover: $34.99
save 33%!
Free Shipping!
UK, US, Europe and selected countries in Asia.
Also available on:
Table of Contents
Sample Chapters
  • Tips and tricks for topics ranging from point-and-click administration, to fine development techniques with Apex & Visualforce
  • Avoids technical jargon, and expresses concepts in a clear and simple manner
  • A pocket guide for experienced developers

Book Details

Language : English
Paperback : 224 pages [ 235mm x 191mm ]
Release Date : February 2013
ISBN : 184968474X
ISBN 13 : 9781849684743
Author(s) : Abhinav Gupta, Ankit Arora
Topics and Technologies : All Books, Application Development, Cloud, Enterprise

Table of Contents

Chapter 1: Learning to Fly with
Chapter 2: Admin Tools
Chapter 3: Making Best Use of Salesforce Objects
Chapter 4: Understanding Analytics
Chapter 5: Setting Up Development Environments
Chapter 6: Tools and Destinations that Every Developer Should Know
Chapter 7: Writing Better Apex Code
Chapter 8: Writing Better Visualforce Code
  • Chapter 1: Learning to Fly with
    • What is cloud computing?
      • Infrastructure as a service (IaaS)
      • Platform as a service (PaaS)
      • Software as a service (SaaS)
    • What is
      • What empowers
        • Multitenancy
        • Metadata
      • Understanding the stack
        • Infrastructure as a service
        • Database as a service
        • Integration as a service
        • Logic as a service
        • User interface as a service
        • Development as a service
        • AppExchange
      • Introduction to governor limits
    • Salesforce environments
    • Summary
    • Chapter 2: Admin Tools
      • Data Loader
        • When to use Data Loader
        • Strategy to import data
          • Identifying data sources
          • Data preparation
          • Testing the data import
          • Analyzing the test import
          • Final data import
          • Validating the import
        • Using Data Loader for data export
        • Using Data Loader for uploading attachments
      • The Import wizard
        • When to use the Import wizard
        • Notes on data import
        • Undoing data import
      • Third-party tools for data integration
      • Integrated Development Environment (IDE)
        • IDE communication
        • perspective
        • Problems view
        • Execute Anonymous view
        • Apex Test Runner view
        • Schema explorer
        • Deployment
      • Migration Tool
      • AppExchange – cloud application marketplace
        • DupeCatcher – real-time deduplication
        • Milestones PM – project and task management
        • Salesforce CRM dashboards
        • Salesforce for Twitter and Facebook (v4)
        • Appirio Contact Sync for Salesforce and Google Apps
        • Ribbit for Salesforce
        • SnapShot Change And Release Management
        • Salesforce Adoption Dashboards (2011)
        • Survey Force
        • Draggin' Role
        • Find Nearby – Accounts, Contacts, Leads – Managed, PE/EE/UE/DE
        • AppExchange Dashboard Pack
        • Action Plans – v3 – Unmanaged – EE, UE, and DE
        • Project and Issue Management
        • CloudConverter for
        • Opportunity Planning Wall
        • Data Loader – Salesforce integration
        • Mass Edit + Mass Update + Mass Delete
        • Implementation Cloud – project management app
        • S-Docs – free document generator (PDF, Word, Excel)
        • CMSForce 2
        • FormFactory quotes and invoices
        • Chatter Usage Dashboards – Labs
        • FinancialForce Accounting for Salesforce
        • Professional Services Automation – PSA for Salesforce
        • CVM Supplier Central Enterprise Edition
        • CVM Supplier Locator
      • Summary
      • Chapter 3: Making Best Use of Salesforce Objects
        • Understanding the field types
          • Basic non-relational field types
          • Relational field types
          • Identity fields
          • System fields
          • The Name field
          • Additional database features
        • Considerations for relationships
        • Types of objects
          • Standard objects
            • Account
            • Contact
            • Lead
            • Campaign
            • Opportunity
            • Forecast
            • Quote
            • Product and price book
            • Case
          • Custom objects
            • Design approach
            • Implementation steps
            • Tips
        • Record types
        • Summary
        • Chapter 4: Understanding Analytics
          • Report types
            • Tips and considerations for report types
              • Defining report types
              • Choosing object relationships
              • Adding lookup fields
          • Reports
            • Organizing reports
            • Working with reports
              • Creating reports
              • Subtotaling the report results
              • Running reports
              • Scheduling a report
              • Printing and exporting reports
            • Report charts
              • Combination charts
            • Dynamic reports
          • Dashboards
            • Working with dashboards
            • Dashboard filters
            • Dashboard data refresh
          • Analytic snapshots
            • Tips for analytic snapshots
              • Tips on target objects
          • Summary
          • Chapter 5: Setting Up Development Environments
            • Building apps on Salesforce
            • What is an environment?
              • Production environment
              • Development environments
              • Sandbox orgs
                • Configuration-only sandbox
                • Developer sandbox
                • Full sandbox
                • Typical uses of sandboxes
                • Tips for creating or refreshing a sandbox
              • Developer Edition orgs
                • Individual versus partner DE
                • When to use individual DE org
                • When to use partner DE org
              • Tips and best practices
                • Choosing a development environment
                • Development considerations
              • Testing environments
                • When to use a Partner Test Edition org
                • When to use a sandbox org
              • Various development scenarios
                • Scenario 1
                • Scenario 2
                • Scenario 3
            • Migrating changes between environments
              • Migrating changes manually
                • Establishing a change process for production org
                • Tracking changes
              • Metadata migration
                • Migration using change sets
                • Migrating metadata files
            • Application lifecycle management
              • Production development
              • Developing with sandbox
              • Isolating development and testing
              • Multiple project development with integration, UAT, and staging
              • Developing enterprise applications
            • Summary
            • Chapter 6: Tools and Destinations that Every Developer Should Know
              • Tools for developers and admins
                • Choosing the right IDE
                  • IDE based on Eclipse
                  • Developer console based on your browser
                  • Sublime Text plugin for
                • Exploring objects, fields, and relationships using Schema Browsers
                  • Schema Builder
                  • Explorer
                  • SoqlXplorer
                • Data Loaders
                  • Data Loader for Windows
                  • Excel Connector
                  • LexiLoader for Mac OS
                • Utility tools and apps for productivity boost
                  • migration tool
                  • Salesforce Workbench
                  • Security Code Scanner
                  • Utility Belt
                  • Trapdoor (Mac OS only)
                • Toolkits and libraries
              • Destinations
                • Open source goodness
                • Queries and troubleshooting
              • Summary
              • Chapter 7: Writing Better Apex Code
                • Understanding the language basics
                  • Using the correct nomenclature for code files
                  • Language constructs
                    • Finding what's different with static keywords
                    • Simplifying the loops
                    • Making constants better with enums
                    • Reducing script statements
                • Advanced Apex
                  • Security data access via the with sharing keyword in classes
                  • Enforcing CRUD and FLS
                  • Writing better SOQL queries
                    • Query-required fields only
                    • Using SOQL for loops
                    • Executing selective and index-based queries
                    • Combining multiple SOQLs to avoid governor limits
                    • Fixing SOQL that returns a single record
                    • Making the most out of dynamic SOQL
                  • Taking control on DML operations
                    • Controlling transaction commits and rollbacks
                    • Fine-tuning with extra DML options
                    • Error handling during DML operations
                  • Decoding the Apex Describe Information
                    • Getting info about sObjects and associated fields
                    • Accessing/updating the sObject records based on field names
                    • Getting SobjectType from ID
                    • Instantiating classes dynamically
                  • Writing better triggers
                    • Understanding the order of execution for triggers
                    • Writing triggers to handle bulk data
                    • Multiple triggers on an sObject
                  • Handling XML in Apex
                  • Handling JSON in Apex
                  • Packaging considerations with Apex
                  • API version
                    • Changing API versions
                  • Apex testing tips
                    • Isolating test data from org data
                    • Testing with various profiles
                    • Letting your class know about the test context
                  • Apex REST web services
                    • API versioning with REST web services
                  • Knowing the limits
                    • Tracking resource (limit) usage
                • Summary
                • Chapter 8: Writing Better Visualforce Code
                  • Knowing the Visualforce architecture
                  • Reusing the platform's native look and feel
                    • Starting the page design with native headers
                    • Native detail sections/forms
                    • Styling tables to look like native grids
                    • Printing messages in a native style
                    • Native (standard) versus custom controllers/extensions
                  • Reusing VF code
                    • Including other VF pages
                    • Defining templates or page layouts
                    • Defining your own components
                  • Limiting view states
                    • Use the view state inspector
                      • Using static when possible
                    • Trimming the view state by using transient variables
                      • Identifying a transient variable
                    • Avoid multiple forms
                    • Query-required fields only
                    • More tips and tricks on the view state
                  • Flexible pages using field sets
                  • Speeding up Ajax calls
                    • Using the immediate attribute
                    • Re-rendering required components only
                    • Demarcating using action regions
                  • Global variables and functions
                  • JavaScript remoting
                    • Public versus global – using the right access modifier
                    • Making the most out of the method arguments and return types
                    • Handling namespace prefixes in managed packages
                      • Approach 1
                      • Approach 2
                  • Taking care of security compliance in pages
                    • Encode/escape
                    • Enforcing CRUD and FLS
                  • Miscellaneous tips
                    • Querying a million rows
                    • Rendering a page as a PDF
                    • Dynamic VF components
                    • Charts
                  • Summary

                  Abhinav Gupta

                  Abhinav Gupta is a Solution Architect and an expert cloud computing consultant. He is a contributor and an avid blogger, he actively participates on discussion boards, blogs about cloud computing,, and open source technologies at, and also contributes to various open source projects.

                  Abhinav specializes in both native app development and B2B/B2C integrations with other platforms/APIs. His area of expertise is not only limited to, but has done quality work on other cloud platforms like developing JEE apps on Heroku, Amazon Web Services (EC2/BeanStalk etc) and Google App Engine.  He is a “ MVP” with notable achievements that include creating the code share project Tolerado, winning third place in the 2010 Salesforce Developer Challenge with his mobile location sharing application, and frequently being mentioned in the newsletter and blog.

                  Abhinav lives in India with his wife and 3-year-old daughter, and enjoys reading technology books and magazines, playing computer games.

                  Ankit Arora

                  Ankit Arora (@forceguru) is an avid certified professional working on the platform since 2008. Since then, he has been involved in architecting, building and implementing solutions for on-premise and AppExchange applications. He has also won many online challenges rolled out by Salesforce like TwitterTrivia, Hammer of Thor, CloudTrivia etc. Ankit is a MVP (most valuable professional) and Leader of Salesforce Platform Developer Users Group Jaipur. He has been contributing to the Salesforce community in various ways and through various channels. He is passionate about and exhibits the same by actively blogging at "". He is acting as moderator on Salesforce Discussion Boards and shares his knowledge and experience by providing effective and converging solutions to developer queries. He has submitted many cookbook recipes that can be found in the online cookbook. Ankit resides in Jaipur also known as the pink city, located in Rajasthan India, a city that has been able to maintain its rich heritage from the times of Maharajas, yet picking up the pace to emerge as a strong contender for the fastest growing cities in India. Ankit lives with his family and likes to play first person combat games like Counter Strike in his free time. He is an enthusiast sportsman and a national level player in the online Counter Strike competition.
                  Sorry, we don't have any reviews for this title yet.

                  Code Downloads

                  Download the code and support files for this book.

                  Submit Errata

                  Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.

                  Sorry, there are currently no downloads available for this title.

                  Frequently bought together

         Tips and Tricks +    Learning Perforce SCM =
                  50% Off
                  the second eBook
                  Price for both: $31.45

                  Buy both these recommended eBooks together and get 50% off the cheapest eBook.

                  What you will learn from this book

                  • Be more efficient and productive on the platform, not only as a developer but also as an administrator
                  • Manage and use it in a multi-developer environment
                  • Explore various tools and destinations for admins
                  • Make best use of Salesforce objects, reports, and analytics
                  • Explore various tools and destinations for developers
                  • Understand the multitenant nature of the platform
                  • Write better code in both Apex and Visualforce

                  In Detail

         is an extremely powerful, scalable and secure cloud platform, delivering a complete technology stack covering the ground from database and security to workflow and user interface.

         Tips and Tricks starts with very basic admin tasks and gradually moves to hard-core coding tips and tricks for the multitenant platform.

                  The book starts with the basics of Cloud Computing and Principles and constructs of The book then swiftly move to detailed coverage of Salesforce analytics. The book also shows how to set up development environments and and gives detailed understanding of tools and destinations that every developer should know. The book also covers important administration concepts where you gain vital information for key topics such as schema and reporting for an organization. For, troubleshooting a problem and code reuse are two important aspects that help in boosting productivity, a complete chapter is dedicated to these tasks.

                  This book takes you beyond any documentation or course and promises hands-on expertise.


                  " Tips and Tricks" is not a complete reference guide for the platform development but it is a time-saving tips and tricks book that can be very helpful and handy for novice as well as experienced developers. This book would be very useful for developers who want to extend their applications using Flex, Apex, and Visualforce.

                  Who this book is for

                  " Tips and Tricks" is not a bible or a complete reference for the platform development. The time- saving tips and tricks make this book handy for novice as well as experienced developers. This is basically for developers, who want to extend their applications using Flex, Apex, and Visualforce.

                  Code Download and Errata
                  Packt Anytime, Anywhere
                  Register Books
                  Print Upgrades
                  eBook Downloads
                  Video Support
                  Contact Us
                  Awards Voting Nominations Previous Winners
                  Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
                  Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software