start-salesforce-with-r

465a530291aedb53fff5a6333e3dedaa?s=47 bk
September 19, 2020

 start-salesforce-with-r

465a530291aedb53fff5a6333e3dedaa?s=128

bk

September 19, 2020
Tweet

Transcript

  1. RͰ࢝ΊΔSalesForce ʙsalesforcerʹΑΔSalesForceσʔλૢ࡞ʙ

  2. ໨࣍ ૝ఆࢹௌऀͱ໨త……………………………………………………Q ࠓ೔࿩͞ͳ͍͜ͱ……………………………………………………Q SalesForceͱ͸………………………………………………………Qd salesforcerͱ͸………………………………………………………Qd ΦϒδΣΫτͱ͸……………………………………………………Qd SOQLͱ͸………………………………………………………………Qd Ϩϙʔτͱ͸……………………………………………………………Qd ࢀߟจݙ……………………………………………………………………Q salesforce

  3. ૝ఆࢹௌऀͱ໨త ໨త ૝ఆࢹௌऀ جຊ༻ޠʢΦϒδΣΫτɺSOQLʣ ΛRΛ௨ͯ͠ཧղ͢Δɻ • SalesForceΛ໊લ͔͠஌Βͳ͍ • R͸࢖༻͍ͯ͠Δ •

    ϚʔέςΟϯάͱؔΘΓ͕͋Δ • GUIʹ௚઀৮Γͨ͘ͳ͍
  4. ߴ౓ͳ͜ͱ → ೖ໳ฤͳͷͰ ։ൃͷ͜ͱ → ҰൠϢʔβʔΛ૝ఆʢDeveloper Console͸ͪΐͬͱ࢖͏ʣ Ϩϙʔτܥ → ௐࠪෆ଍ͷͨΊʢεϥΠυ͸͋Δ͚Ͳؒҧ͍͋Δ͔΋ʣ

    ࠓ೔࿩͞ͳ͍͜ͱ
  5. SalesForceͱ͸ salesforce

  6. SalesForceͱ͸ Salesforce͸ɺاۀͱސ٬Λͭͳ͙ސ٬؅ཧιϦϡʔγϣϯɻϚʔέςΟϯάɺӦ ۀɺίϚʔεɺαʔϏεͳͲ͢΂ͯͷ෦ॺͰɺސ٬ҰਓͻͱΓͷ৘ใΛҰݩతʹڞ ༗Ͱ͖Δ౷߹CRMϓϥοτϑΥʔϜͰ͢ɻ https://www.salesforce.com/jp/products/what-is-salesforce/ https://www.salesforce.com/campaign/worlds-number-one-CRM/

  7. https://www.salesforce.com/jp/hub/crm/what-is-crm/ SalesForceͱ͸ CRMͱ͸ʮCustomer Relationship ManagementʯͷུͰɺ೔ຊޠͰ͸ʮސ ٬ؔ܎؅ཧʯͱݺ͹Ε·͢ɻސ٬ͱͷؔ܎ੑɺίϛϡχέʔγϣϯΛ؅ཧ ͠ɺࣗࣾͷैۀһͱސ٬ͱͷؔ܎ΛҰݩతʹ೺ѲͰ͖ΔΑ͏ʹ͠·͢ɻ

  8. SalesForceͱ͸ ຊ೔͸ແྉͰ৮ΕΔσϞΞΧ΢ϯτͰਐΊΔɻ https://developer.salesforce.com/signup

  9. SalesForceͱ͸ σϞΞΧ΢ϯτొ࿥׬ྃޙͷτοϓϖʔδɻ

  10. Ͱ΍ͬͯΈΑ͏

  11. salesforcerͱ͸

  12. https://stevenmmortimer.github.io/salesforcer/index.html salesforcerͱ͸ ϦϦʔε೔ɿ ࠷৽Ξοϓσʔτ೔ɿ ։ൃऀ໊ɿSteven M. Mortimer ʢݱࡏʣ RͰSalesForceΛૢ࡞Ͱ͖Δlibraryɻ

  13. salesforcerͱ͸ or OAuth libraryΛΠϯετʔϧޙɺೝূ৘ใΛઃఆͯ͠઀ଓɻ Ϣʔβʔ໊ɺύεϫʔυɺηΩϡϦςΟτʔΫϯ͕ඞཁɻ ʢIP੍ݶֻ͕͔͍ͬͯΔͱηΩϡϦςΟτʔΫϯ͕औಘͰ͖ͳ͍ʣ

  14. sf_user_infoͰ઀ଓ৘ใͷ֬ೝɻlistܗࣜͰฦ͞ΕΔɻ salesforcerͱ͸

  15. ΦϒδΣΫτͱ͸

  16. ΦϒδΣΫτͱ͸ ΦϒδΣΫτ ≒ ςʔϒϧ

  17. ΦϒδΣΫτͱ͸ SalesForceͷ্෦ʹλϒঢ়ʹ͋Δɺͻͱͭͻͱ͕ͭΦϒδΣΫτɻ

  18. https://trailhead.salesforce.com/ja/content/learn/modules/lex_salesforce_basics/lex_salesforce_basics_welcome ΦϒδΣΫτͱ͸ ΦϒδΣΫτʹ͸ॳΊ͔Β༻ҙ͞Ε͍ͯΔʮඪ४ΦϒδΣΫτʯͱɺϢʔ βʔ͕࡞੒͢ΔʮΧελϜΦϒδΣΫτʯ͕͋ΔɻԼͷਤ͸ඪ४ΦϒδΣΫ τͷҰ෦ɻ

  19. ͰΦϒδΣΫτҰཡΛऔಘ͢Δ

  20. ΦϒδΣΫτͱ͸ sf_list_objectsͰऔಘɻlistܗࣜͰฦ͞ΕΔɻ

  21. Ͱ΍Δͱʁ salesforce

  22. ΦϒδΣΫτͱ͸ ઃఆ͔ΒDeveloper ConsoleΛ։͘ɻ

  23. ΦϒδΣΫτͱ͸ File͔ΒOpen ResourceΛ։͘ɻ

  24. ΦϒδΣΫτͱ͸ ݕࡧ૭Ͱʮ.objʯͰऴΘΔ΋ͷΛݕࡧɻ

  25. SOQLͱ͸

  26. SOQLͱ͸ SOQLʢSalesforce Object Query Languageʣ ≒ SQLʢ*Structured Query Languageʣ *ANSIن֨ͷSQLͱ͍͏໊শ͸ެࣜʹ͸ԿͷུͰ΋ͳ͍ͱ͞ΕΔɻ

    http://e-words.jp/w/SQL.html
  27. ͰΦϒδΣΫτͷத਎Λऔಘ͢Δ

  28. SOQLͱ͸ sf_queryʹจࣈྻΛ౉͢ɻFROMʹΦϒδΣΫτΛࢦఆɻ

  29. Ͱ΍Δͱʁ salesforce

  30. ઃఆ͔ΒDeveloper ConsoleΛ։͘ɻ SOQLͱ͸

  31. SOQLͱ͸ Query EditorΛબ୒͠ɺΫΤϦΛهड़ɺExecuteΛԡ͢ɻ

  32. SOQLͱ͸ தԝͷը໘ʹ݁Ռ͕දࣔ͞ΕΔɻ

  33. Ϩϙʔτͱ͸

  34. Ϩϙʔτͱ͸ Ϩϙʔτ ≒ ΦϒδΣΫτΛूܭͨ͠΋ͷ

  35. Ϩϙʔτͱ͸ τοϓϖʔδͷλϒʹଘࡏ͢Δɻ

  36. ͰϨϙʔτΛ࡞੒͢Δ

  37. Ϩϙʔτͱ͸ sf_create_reportͰϕʔεͷϨϙʔτΛ࡞੒͔ͯ͠ΒɺϑΟϧλΛઃఆͯ͠ sf_run_reportͰ࠶౓࡞੒͢Δɻ

  38. Ͱ΍Δͱʁ salesforce

  39. Ϩϙʔτͱ͸ Ϩϙʔτը໘ͷNew Reportʢ৽نϨϙʔτʣΛ࣮ߦɻ

  40. Ϩϙʔτͱ͸ ूܭର৅ͱͳΔΦϒδΣΫτΛબ୒ɻ

  41. Ϩϙʔτͱ͸ FilterͰ৚݅Λઃఆɻ

  42. Ϩϙʔτͱ͸ ूܭ݁Ռ͕ը໘தԝʹදࣔ͞ΕΔɻ

  43. ·ͱΊ SalesForceͱ͸ salesforcerͱ͸ ΦϒδΣΫτͱ͸ SOQLͱ͸ Ϩϙʔτͱ͸ CRMϓϥοτϑΥʔϜ RͰSalesForceΛૢ࡞͢Δlibrary SalesForceͷςʔϒϧ SalesForceͷSQL

    ΦϒδΣΫτΛूܭͨ͠΋ͷ
  44. ɾTRAILHEAD https://trailhead.salesforce.com/ja/home ɾGitHub, ʮAn Implementation of Salesforce APIs Using Tidy

    Principles • salesforcerʯ https://stevenmmortimer.github.io/salesforcer/index.html ɾCRAN, ʮPackage salesforcerʯ https://cloud.r-project.org/web/packages/salesforcer/index.html ɾQiita, ʮΤϯδχΞͷͨΊͷsalesforce௒ೖ໳ʯ https://qiita.com/tarokamikaze/items/0bc2988534f63d4b65c5 ࢀߟจݙ
  45. ENJOY!