Skip to content

Commit e9cf042

Browse files
Apply suggestions from code review
Co-authored-by: forstisabella <[email protected]>
1 parent 6ef53d3 commit e9cf042

File tree

1 file changed

+23
-30
lines changed
  • src/connections/destinations/catalog/actions-singlestore

1 file changed

+23
-30
lines changed

src/connections/destinations/catalog/actions-singlestore/index.md

Lines changed: 23 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -21,72 +21,65 @@ This destination is maintained by SingleStore. For any issues with the destinati
2121
4. Enter a name for your SingleStore (Actions) destination, update any additional settings, then click **Save**.
2222
6. Navigate to the Mappings tab for your SingleStore destination and click **New Mapping**.
2323
7. Select **Send Data**.
24-
8. Within "Map fields", select your database from the list presented
25-
9. Click "Next" and then "Save"
26-
10. Voila! Your data should start flowing into your SingleStore database within moments.
24+
8. In the Map fields section, select your database from the list presented.
25+
9. Click **Next** and then **Save**.
2726

2827
{% include components/actions-fields.html %}
2928

3029
### Finding your SingleStore connection settings
31-
You can generally find your SingleStore connection settings by heading to the [SingleStore Portal](https://portal.singlestore.com) and following these steps:
32-
1. Select "Deployments"
30+
To find your SingleStore connection settings, head to the [SingleStore Portal](https://portal.singlestore.com){:target="_blank”} and complete the following steps:
31+
1. Select **Deployments**.
3332
2. Choose your Workspace and Database within the list of Deployments
34-
3. Click "Connect" dropdown
35-
4. Choose Connect to your own app and that will provide the key settings
33+
3. From the Connect dropdown, select **Connect to your own app**. SingleStore will display the the key settings you need to connect your SingleStore database to Segment.
3634

37-
## The database structure
38-
Segment creates a table called `segment_raw_data` and writes data to your SingleStore database using the following schema.
35+
## Database structure
36+
Segment creates a table called `segment_raw_data` and writes data to your SingleStore database using the following schema:
3937

40-
### Columns in the segment_raw_data table
41-
|Column| Type |Description|
42-
|-|-|-|
43-
|`message`| JSON (utf8_bin)| The entire message received from Segment in JSON format|
44-
|`timestamp`| datetime| The timestamp of when the event was generated|
45-
|`event`| VARCHAR(255)| The event name (for Track events)|
46-
|`messageId`| VARCHAR(255)| The unique identifier of the event to ensure there is no duplication|
47-
|`type`| VARCHAR(255)| The type of the event (e.g., identify, track, page, group)|
38+
| Column | Type | Description |
39+
| -------- | ------ | ----------- |
40+
| `message` | JSON (utf8_bin) | The entire message received from Segment, in JSON format |
41+
| `timestamp` | datetime | The timestamp of when the event was generated |
42+
| `event` | VARCHAR(255) | The event name (for Track events) |
43+
| `messageId` | VARCHAR(255) | The unique identifier of the event to ensure there is no duplication |
44+
| `type` | VARCHAR(255) | The type of the event (for example, Identify, Track, Page, Group) |
4845

4946

50-
### Accessing Nested Data
47+
### Accessing nested data
5148
To query specific data from the Segment event within SingleStore, you can de-reference the JSON pointer within the message column. For example:
52-
```
49+
50+
```sql
5351
SELECT message::properties FROM segment_raw_data;
5452
```
53+
5554
This query retrieves the properties object from the JSON message, allowing you to work with nested event data.
5655

5756
## Troubleshooting
5857

5958
### Connection Errors
60-
**Issue:** Unable to connect to the SingleStore database.
61-
62-
**Solution:**
59+
If you're unable to connect to the SingleStore database:
6360
* Verify that the Host and Port are correct.
6461
* Ensure that your SingleStore database is accessible from Segment’s servers.
6562
* Check firewall settings and network configurations.
6663

6764
### Authentication Failures
68-
**Issue:** Authentication errors when Segment attempts to connect.
69-
70-
**Solution:**
65+
If you encounter authentication errors when Segment attempts to connect:
7166
* Confirm that the Username and Password are correct.
7267
* Ensure that the user has the necessary permissions to write to the database.
7368

7469
### Data Not Appearing in SingleStore
75-
**Issue:** Events are not being recorded in the segment_raw_data table.
76-
77-
**Solution:**
70+
If events are not recorded in the `segment_raw_data` table:
7871
* Verify that your sources are correctly sending data to Segment.
7972
* Check the event types to ensure they are supported.
8073
* Review your SingleStore database logs for any errors.
8174

8275
## Frequently Asked Questions
8376
### Can I customize the schema used in SingleStore?
8477

85-
By default, the mapping is predefined to store the complete raw Segment events in the segment_raw_data table. If you prefer, within the mapping, you can choose to selectively include or exclude specific fields to be sent and written into SingleStore.
78+
By default, the mappings store the complete raw Segment events in the `segment_raw_data` table. If you prefer, within the mapping, you can choose to selectively include or exclude specific fields to be sent and written into SingleStore.
8679

8780
### How does SingleStore handle data types from Segment?
8881

89-
All event data is stored natively as JSON within the message column. This allows for flexible schema management and easy access to nested properties using SQL queries. SingleStore's ability to dynamically and quickly parse the JSON allows all types of complex events to be queried or used in notebooks.
82+
All event data is stored natively as JSON in the message column. This allows for flexible schema management and easy access to nested properties using SQL queries. SingleStore's ability to dynamically and quickly parse the JSON allows all types of complex events to be queried or used in notebooks.
9083

9184
### Is the data ingestion process real-time?
9285

0 commit comments

Comments
 (0)