<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Salesforce on kenji.blog</title><link>http://kenji.blog/en/tags/salesforce/</link><description>Recent content in Salesforce on kenji.blog</description><generator>Hugo -- gohugo.io</generator><language>en</language><copyright>kenjinote</copyright><lastBuildDate>Sun, 09 Apr 2023 02:50:30 +0900</lastBuildDate><atom:link href="http://kenji.blog/en/tags/salesforce/index.xml" rel="self" type="application/rss+xml"/><item><title>How to Get the Daily Record Creation Count Using SOQL in Salesforce</title><link>http://kenji.blog/en/p/salesforce%E3%81%AEsoql%E3%82%92%E5%88%A9%E7%94%A8%E3%81%97%E3%81%A6%E6%97%A5%E5%88%A5%E3%81%AE%E3%83%AC%E3%82%B3%E3%83%BC%E3%83%89%E4%BD%9C%E6%88%90%E6%95%B0%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95/</link><pubDate>Sun, 09 Apr 2023 02:50:30 +0900</pubDate><guid>http://kenji.blog/en/p/salesforce%E3%81%AEsoql%E3%82%92%E5%88%A9%E7%94%A8%E3%81%97%E3%81%A6%E6%97%A5%E5%88%A5%E3%81%AE%E3%83%AC%E3%82%B3%E3%83%BC%E3%83%89%E4%BD%9C%E6%88%90%E6%95%B0%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95/</guid><description>&lt;img src="http://kenji.blog/p/salesforce%E3%81%AEsoql%E3%82%92%E5%88%A9%E7%94%A8%E3%81%97%E3%81%A6%E6%97%A5%E5%88%A5%E3%81%AE%E3%83%AC%E3%82%B3%E3%83%BC%E3%83%89%E4%BD%9C%E6%88%90%E6%95%B0%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95/img.png" alt="Featured image of post How to Get the Daily Record Creation Count Using SOQL in Salesforce" />&lt;h1 id="how-to-get-the-daily-record-creation-count-using-soql-in-salesforce">How to Get the Daily Record Creation Count Using SOQL in Salesforce
&lt;/h1>&lt;ol>
&lt;li>Open the Developer Console.&lt;/li>
&lt;li>Open the &lt;code>Query Editor&lt;/code> tab.&lt;/li>
&lt;li>Paste and execute the following SOQL query.&lt;/li>
&lt;/ol>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre tabindex="0" class="chroma">&lt;code>&lt;span class="lnt">1
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre tabindex="0" class="chroma">&lt;code class="language-sql" data-lang="sql">&lt;span class="line">&lt;span class="cl">&lt;span class="k">select&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="n">day_only&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="n">createdDate&lt;/span>&lt;span class="p">),&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="k">count&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="n">createdDate&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="k">from&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="n">account&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="k">group&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="k">by&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="n">day_only&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="n">createdDate&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="k">order&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="k">by&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="k">count&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="n">createdDate&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="k">desc&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="k">limit&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="mi">10&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>Change &lt;code>account&lt;/code> to the name of any object you want to query before executing.&lt;/p>
&lt;h1 id="reference">Reference
&lt;/h1>&lt;ul>
&lt;li>&lt;a class="link" href="https://stackoverflow.com/questions/9187737/is-there-a-way-to-group-by-the-date-portion-of-a-datetime-field-in-soql" target="_blank" rel="noopener"
>Is there a way to group by the date portion of a datetime field in SOQL?&lt;/a>&lt;/li>
&lt;/ul></description></item><item><title>Salesforce Chatter Bulk Delete Command</title><link>http://kenji.blog/en/p/salesforce%E3%83%81%E3%83%A3%E3%83%83%E3%82%BF%E3%83%BC%E5%85%A8%E6%B6%88%E3%81%97%E3%82%B3%E3%83%9E%E3%83%B3%E3%83%89/</link><pubDate>Mon, 19 Sep 2022 21:59:14 +0900</pubDate><guid>http://kenji.blog/en/p/salesforce%E3%83%81%E3%83%A3%E3%83%83%E3%82%BF%E3%83%BC%E5%85%A8%E6%B6%88%E3%81%97%E3%82%B3%E3%83%9E%E3%83%B3%E3%83%89/</guid><description>&lt;img src="http://kenji.blog/p/salesforce%E3%83%81%E3%83%A3%E3%83%83%E3%82%BF%E3%83%BC%E5%85%A8%E6%B6%88%E3%81%97%E3%82%B3%E3%83%9E%E3%83%B3%E3%83%89/img_1.png" alt="Featured image of post Salesforce Chatter Bulk Delete Command" />&lt;h1 id="salesforce-chatter-bulk-delete-command">Salesforce Chatter Bulk Delete Command
&lt;/h1>&lt;p>This is a command to delete all posts and attachments in Salesforce Chatter.
Open the Developer Console, select &amp;ldquo;Open Execute anonymous Window&amp;rdquo; from the Debug menu, paste the following code, and execute it.
I personally use this when the organization&amp;rsquo;s storage capacity is running low.&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre tabindex="0" class="chroma">&lt;code>&lt;span class="lnt">1
&lt;/span>&lt;span class="lnt">2
&lt;/span>&lt;span class="lnt">3
&lt;/span>&lt;span class="lnt">4
&lt;/span>&lt;span class="lnt">5
&lt;/span>&lt;span class="lnt">6
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre tabindex="0" class="chroma">&lt;code class="language-fallback" data-lang="fallback">&lt;span class="line">&lt;span class="cl">delete [select id from FeedItem];
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">delete [select id from FeedAttachment];
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">delete [select id from ContentDocument];
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">// Empty the recycle bin
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">database.emptyRecycleBin([select id from ContentDocument where IsDeleted = true ALL ROWS]);
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div></description></item><item><title>Recommended Chrome Extensions for Salesforce</title><link>http://kenji.blog/en/p/salesforce%E3%81%8A%E3%81%99%E3%81%99%E3%82%81chrome%E6%8B%A1%E5%BC%B5/</link><pubDate>Mon, 02 May 2022 10:39:36 +0900</pubDate><guid>http://kenji.blog/en/p/salesforce%E3%81%8A%E3%81%99%E3%81%99%E3%82%81chrome%E6%8B%A1%E5%BC%B5/</guid><description>&lt;img src="http://kenji.blog/p/salesforce%E3%81%8A%E3%81%99%E3%81%99%E3%82%81chrome%E6%8B%A1%E5%BC%B5/img.png" alt="Featured image of post Recommended Chrome Extensions for Salesforce" />&lt;h3 id="salesforce-devtools">Salesforce DevTools
&lt;/h3>&lt;p>&lt;img src="http://kenji.blog/p/salesforce%E3%81%8A%E3%81%99%E3%81%99%E3%82%81chrome%E6%8B%A1%E5%BC%B5/img_1.png"
width="454"
height="361"
srcset="http://kenji.blog/p/salesforce%E3%81%8A%E3%81%99%E3%81%99%E3%82%81chrome%E6%8B%A1%E5%BC%B5/img_1_huf57bbbba5c728384e7ba6fa16d7a54c4_18951_480x0_resize_box_3.png 480w, http://kenji.blog/p/salesforce%E3%81%8A%E3%81%99%E3%81%99%E3%82%81chrome%E6%8B%A1%E5%BC%B5/img_1_huf57bbbba5c728384e7ba6fa16d7a54c4_18951_1024x0_resize_box_3.png 1024w"
loading="lazy"
alt="img_1.png"
class="gallery-image"
data-flex-grow="125"
data-flex-basis="301px"
>&lt;/p>
&lt;p>&lt;img src="http://kenji.blog/p/salesforce%E3%81%8A%E3%81%99%E3%81%99%E3%82%81chrome%E6%8B%A1%E5%BC%B5/img_2.png"
width="448"
height="909"
srcset="http://kenji.blog/p/salesforce%E3%81%8A%E3%81%99%E3%81%99%E3%82%81chrome%E6%8B%A1%E5%BC%B5/img_2_huf368a70f31f9534fa7902adae2b30e6e_26924_480x0_resize_box_3.png 480w, http://kenji.blog/p/salesforce%E3%81%8A%E3%81%99%E3%81%99%E3%82%81chrome%E6%8B%A1%E5%BC%B5/img_2_huf368a70f31f9534fa7902adae2b30e6e_26924_1024x0_resize_box_3.png 1024w"
loading="lazy"
alt="img_2.png"
class="gallery-image"
data-flex-grow="49"
data-flex-basis="118px"
>&lt;/p>
&lt;p>You can search for custom fields and export the fields of custom objects in bulk.&lt;/p>
&lt;p>It&amp;rsquo;s also convenient to be able to build SOQL on the spot.&lt;/p>
&lt;p>&lt;a class="link" href="https://chrome.google.com/webstore/detail/salesforce-devtools/ehgmhinnhggigkogkbhnbodhbfjgncjf" target="_blank" rel="noopener"
>Salesforce DevTools&lt;/a>&lt;/p>
&lt;h3 id="salesforce-advanced-code-searcher">Salesforce advanced Code searcher
&lt;/h3>&lt;p>&lt;img src="http://kenji.blog/p/salesforce%E3%81%8A%E3%81%99%E3%81%99%E3%82%81chrome%E6%8B%A1%E5%BC%B5/img.png"
width="257"
height="261"
srcset="http://kenji.blog/p/salesforce%E3%81%8A%E3%81%99%E3%81%99%E3%82%81chrome%E6%8B%A1%E5%BC%B5/img_huc75a5c8c4d45e738551ca5afb26f380b_13227_480x0_resize_box_3.png 480w, http://kenji.blog/p/salesforce%E3%81%8A%E3%81%99%E3%81%99%E3%82%81chrome%E6%8B%A1%E5%BC%B5/img_huc75a5c8c4d45e738551ca5afb26f380b_13227_1024x0_resize_box_3.png 1024w"
loading="lazy"
alt="img.png"
class="gallery-image"
data-flex-grow="98"
data-flex-basis="236px"
>&lt;/p>
&lt;p>This is useful when searching for Salesforce code.&lt;/p>
&lt;p>&lt;a class="link" href="https://chrome.google.com/webstore/detail/salesforce-advanced-code/lnkgcmpjkkkeffambkllliefdpjdklmi" target="_blank" rel="noopener"
>Salesforce advanced Code searcher&lt;/a>&lt;/p></description></item></channel></rss>