Streams in the CRM
Bring rows from another system into the CRM on a schedule, such as a customer's orders from your ordering system's database or customers from a table in your warehouse.
A stream brings rows from another system into the CRM on a schedule: a customer's orders from the database your ordering system writes to, or customers from a table already in your warehouse. Each run reads what is new or changed since the last one, and each row becomes a deal, a company or a person, matched exactly as an imported CSV's rows are. An order from another system is a deal with its lines, found again by its number (see how orders come in). A row brought in before is found again and kept up to date, never made twice.
Streams are optional. Typing records in, importing a CSV and the lead address always work without one. Owners and admins set them up under Streams, in Set up at the foot of the CRM's left rail.
Email intake, just under Streams in the left rail, is another way rows come in. It takes the orders, purchase orders and customer lists your suppliers and customers email to your CRM's own address, rather than reading another system on a schedule, and it does not count against your plan's streams. See email intake.
Streams on each plan
| Standard | Premium | |
|---|---|---|
| Streams | 1 stream | 5 streams |
| Suggest with Sam | Not included | Included |
Streams are part of your CRM licences: a run is never billed, and a CRM inside a Sanda workspace does not count its CRM streams against the workspace's edition. The page says how many of the plan's streams are in use. A stream past what the plan includes is marked Over the plan and waits, without running, until the plan has room for it again. When Standard's stream is in use, the link beside the count switches you to Premium under Settings · Plan.
Make a stream
Streams shows your streams first, then every system Sanda can read, as a card each. Search them, or narrow them with the chips above them, such as Databases or Commerce. A card says what pressing it does:
- Connected: in a Sanda workspace, a system the workspace already pulls into its warehouse, such as Shopify or Xero, with the name of each connection or pull. These come first. Pressing one makes a stream from that system's own tables.
- Ready: the CRM reads it today. Pressing it makes a stream.
- Postgres: a database your ordering or accounts system writes to.
- Your Sanda warehouse: any table a connection or a pull already keeps in your workspace's warehouse, read where it is. A CRM on its own has no other tables in its warehouse, so it does not show this card.
- Coming soon: on its way to the CRM, such as Google Sheets.
- Connect: in a Sanda workspace, a system it does not pull yet. Pressing it offers Connect in Sanda, which opens the console's Pull page to connect it. Once its first sync lands, its card says Connected. Ask the Sanda team instead sends a request (below).
- Request: in a CRM on its own, Sanda reads it but a CRM stream does not yet. Pressing it asks the Sanda team to switch it on for your CRM, with what you would like from it if you say, and they reply by email. Something else, at the end, asks for a system that has no card.
A stream is made in three steps, and nothing runs until you save it:
- Connect. For Postgres, choose a database you have connected, or connect one (below). Your warehouse needs no sign-in, so it starts at the next step.
- Choose. Choose The table, then what to Bring its rows in as: orders, companies, people or deals, by your CRM's own name for each: the one you gave under Settings · Names, or the one every CRM starts with. A first guess is made from the table's name, and the line under your choice says what each row needs (below). The stream's messages and its runs use the same names, so a Consulting CRM's stream brings in clients where a General CRM's brings in companies.
- Check. Preview shows the table's first rows as the CRM will take them, and says why it cannot take a row. Choose How often it runs (every hour, every six hours, every morning at 6 or every Monday at 6, on your workspace's own time), give it a Name or keep the one made from the table, and press Save and run now, or Save to wait for its first scheduled run.
Which column is which is matched from the columns' names, so most tables need nothing more. Check columns shows each column with a few of its values beside it and what it becomes: change any, or set it to Leave it out. A column whose name says it holds a secret, such as a password, a key or a card number, shows Values withheld instead: its values are left out of the preview and never sent to Sam. It also has What says a row is new or changed: a time, a date or a whole number column, such as an updated time, so each run reads only the rows where it has moved on since the run before. In a table in your warehouse, only a column that always has a value is offered; in a view, which cannot say, a row with no value in it is not read until it has one, and each run says how many there are. When the names do not say enough, Check columns opens by itself.
On Premium, when the names do not say enough, Sam matches the columns from their names and a few of their values as you reach Check, and Suggest with Sam under Check columns asks again. Sam only fills in the matches: check them, change any you like, and nothing is saved until you press Save.
What each stream needs
A stream runs again and again, so every row must say enough for the CRM to find it next time:
| The rows become | Each row needs |
|---|---|
| Orders | Its order number, its day and its customer |
| Companies | Its name |
| People | Their name and their email |
| Deals | A name, and either an email or a company |
A company is found by its domain, then by its name, and a person by their email. A deal already here is the one with the same name and the same person's email, or with no email the same company. An order is found by its order number. A number or an amount in a row is read the way people write one, so $1,250.50 and 1,250.50 AUD both land as 1250.5, and one that cannot be read for sure, such as a range, is refused with the reason (see how a number is read).
Connect a database
Connect a database asks for the database's Host, Port, Database, Username and Password, and a Name to know it by. Sanda signs in and reads from it before keeping it, so a wrong password or a database that cannot be reached is said straight away. Use a user that can only read the tables you want: the password is sealed and never shown again.
The database must be reachable from the internet. An address on your own network, such as 192.168.1.20 or localhost, is refused.
A database connected earlier is asked again each time you choose its table, look at its first rows or save. If it turns the password away, the window says so and that you connect it again under Streams; if it does not answer, the window says it could not be reached, and you can try again in a minute.
What a run does
Each run reads the rows that are new or changed, up to 20,000, and brings them in the way an import of the same rows would. A run that reaches the most stops there, and the next carries on from exactly where it got to.
On a table in your warehouse, each run starts a little before where the last one got to (ten minutes back on a time, a day back on a date), so a row stamped earlier that only lands later is still read. A row read again is found unchanged. Only the run straight after one that stopped at the most starts exactly where that one stopped, whether or not it finds anything new, and every run after it reads back again.
- A new row makes a new record, whose history says it was Brought in by The stream and its name.
- A record brought in before has its empty fields filled from the row. A value already in the CRM, such as one somebody typed, is never overwritten.
- An order follows its source: when its day, value, summary, status or delivery day changes there, or one of its lines does, the CRM's copy changes with it. A row can be a whole order, or one line of it with the order's number beside it. Once somebody changes the order in the CRM (its status, a line or an invoice), the CRM's copy is the one that is true: the stream leaves it as it is, and its rows are refused with the reason. An order number the CRM already has for another customer, such as one imported from an old system that counted from the same number, is never written over: that row is refused, and says why. See orders.
- A row the CRM cannot take, such as an order with no customer, is counted and kept with its reason in the run, and the rest still come in.
- A day is read on your workspace's calendar, so an order placed late in the evening is that evening's order, not the next day's. A deal brought in at a won or lost stage closes on your workspace's today, too, unless its row says the day it closed: a stream of deals can carry each one's Number, Opened on, Ordered on and Closed on, so deals from the past keep their own days.
A table in a database is copied into your warehouse first, the way a pull's tables are, and the CRM reads it from there. A row that is deleted from the source is not deleted from the CRM.
Look after a stream
Each stream under Your streams shows where it reads, what it brings in, how often, and how its last run went:
| Status | What it means |
|---|---|
| On | It runs on its schedule |
| Paused | Switched off, or resting while the CRM is read-only |
| Over the plan | The plan has no room for it, so it waits |
| Sign-in refused | The database turned its password away, so nothing comes in. Press Connect again on the stream and type a username and password that work |
| Disconnected | Its database sign-in was disconnected (in a Sanda workspace, from the console's Pull page), so nothing comes in. Press Connect again on the stream and type its username and password |
| Suspended | It failed several runs in a row and was paused. Switch it on to try again |
- Run now starts a run straight away.
- Connect again shows on a stream whose sign-in was refused or disconnected. Type the database's username and password: Sanda signs in and reads from it before keeping them, as it does when you connect a database, and says so if the database turns them away. The stream keeps its database, its table and everything else, and every stream that reads the same database carries on with it.
- Runs lists each run, newest first: whether it was started on its schedule or by hand, what it read from the database, what it brought into the CRM, and each row it could not take, with the reason.
- Edit changes which column is which, how often it runs and its name. It reads the table again, so a column added or renamed since the stream was made can be matched, and saving checks the mapping against the table as it is then. Where it reads from, its table, its new-or-changed column and what its rows become stay as they were made. To change those, make another stream.
- The switch pauses it and turns it back on. Press its name to rename it.
- The bin removes it for good, once you confirm, and its runs go with it. The records it brought in stay in the CRM as they are.
When a run fails, the workspace's owners and admins are emailed about it, at most once a day for each stream, with a link to Streams. The email names the stream and what it could not read (the database, or its table in your warehouse), says what stopped it, and that nothing is lost: the next run carries on from where this one got to. When the database turned the password away, the run says so and that you connect it again under Streams, the stream waits without counting it as a failed run, and the email asks somebody to press Connect again on the stream. In a Sanda workspace this follows the console's Settings · Plan & budget · Budget & alerts: Also send to adds addresses, and When a scheduled run fails, or pauses itself after failing repeatedly turns these emails off.
Something unclear or out of date? Tell us, and we will fix the page.