Skip to content

Instantly share code, notes, and snippets.

@AltiusRupert
AltiusRupert / NamedCredential.cls
Last active May 11, 2023 05:47
Create Salesforce Named Credentials via Apex
// see https://salesforce.stackexchange.com/questions/165551/possible-to-update-namedcredential-from-apex
MetadataService.NamedCredential credential = new MetadataService.NamedCredential();
credential.fullName = 'Demo_Credential';
credential.label = 'Demo Credential';
credential.endpoint = 'https://www.DEMO2.com';
credential.principalType = 'NamedUser';
credential.protocol = 'NoAuthentication';
system.debug(createMetadata(credential));

2015-01-29 Unofficial Relay FAQ

Compilation of questions and answers about Relay from React.js Conf.

Disclaimer: I work on Relay at Facebook. Relay is a complex system on which we're iterating aggressively. I'll do my best here to provide accurate, useful answers, but the details are subject to change. I may also be wrong. Feedback and additional questions are welcome.

What is Relay?

Relay is a new framework from Facebook that provides data-fetching functionality for React applications. It was announced at React.js Conf (January 2015).

@ragingwind
ragingwind / Backend Architectures Keywords and References.md
Last active April 17, 2024 10:51
Backend Architectures Keywords and References
@johncasimiro
johncasimiro / Mimic SQL select * statement in SOQL using Apex
Created December 9, 2010 06:57
A code snippet that mimics the popular Select * SQL syntax in force.com's Apex language.
/*
* @description: A code snippet that mimics the popular Select * SQL syntax in force.com's Apex language.
*/
// Initialize setup variables
String objectName = 'Contact'; // modify as needed
String query = 'SELECT';
Map<String, Schema.SObjectField> objectFields = Schema.getGlobalDescribe().get(objectName).getDescribe().fields.getMap();
// Grab the fields from the describe method and append them to the queryString one by one.