Create, update, and delete records from SQL Server

In this example, we’ll be using Skuid’s OData data source type to pull in info from a SQL Server database.

Step 1: Create a new data source

image0

  1. Navigate to Configure > Data Sources > Data Sources.
  2. Click New Data Source.
  3. Choose OData as the data source type and name the data source.
  4. Click Next Step.
  5. Enter the URL of the service.
  6. Select your OData version.
  7. Click Save.
  8. Click OK.

image2

If prompted to create a remote site setting, click OK to have Skuid create one for you (if you don’t already have one for this URL). Click Cancel to create the Remote Site Setting yourself.

Step 2: Go to the page where you want to add this model or create a new page.

image3

Click Compose to view a list of all Skuid Pages, or Compose > New Page to create a new one.

Step 3: Create a New Model.

image4

  1. Click Models.
  2. Click to add a new Model.
  3. Choose OData as the Data Source Type.
  4. Choose the data source you created earlier in this tutorial.
  5. Start typing and choose the External Object from the list.

Label your model, and choose Fields to order record by, as desired.

image5

  1. Label your model (this is the label that will be displayed to end users).
  2. If you want, specify Fields to order records by.

Step 4: Choose the fields you want to show in your page.

image6

  1. Click Fields.
  2. Check the fields you want to include. Best Practice: Always include the Id field.
  3. Use Search to aid you in your quest.

Drag and drop the fields you picked into any component you want.

image7

  • Just make sure that component is set to your OData model ;)
  • You can also rename these fields so they look nicer. Just click on a field to rename it.

Step 5: Click Save, then click Preview to open your page in a new tab.

image8

Success! You are now able to search, update, create, and delete records from your SQL Server Database right from Salesforce.

image9

Notice that there’s no visual difference between this table and any other Skuid table on data from Salesforce or any other source, so you can view your data as a cohesive whole, regardless of where it comes from. Feel free to add a Title Component to this page though, to remind yourself, like I did, that “This Data comes from SQL Server!”

Troubleshooting Tips