Custom Data Network Visualizer
Instructions on how to set up your own custom data network visualization.

Nodes

The nodes query defines the nodes in the network.
Parameter
Description
id
Id for the node. This will be used by the edges to define the relationships.
title
This is the text that is displayed when hovering on a node.
label
The label that is shown below the node.
value
The visual size of the node relative to other nodes.
mass
The gravitational pull of a node. Unless you really want to customize the visualizer, it is recommended to keep this the same value as the value.
group
Optionally you can associate a node with a group.
color
Optional hex code for the color of a node. The node will take the color of the group if a color is not specified for the node.
description
The description shows up in the top right hand corner when you click a node.
nodeURL
Page to display when you click the open button next to the description.

Edges

The edges query defines the relationships between the nodes.
Parameter
Description
id
Id for the edge.
label
Label that shows up on the edge.
from
Originating node id.
to
Target node id. Can be the same as the from node, it will show a loop back into the same node.
showArrowTo
Set this to True if you want to show the direction of the relationship.
showArrowFrom
Generally should only be used for bi-directional relationships along with the arrow to.

Node Groups

Node groups are an optional query you can provide to group your nodes.
Parameter
Description
sub network
Name for the group
color
Hex value for the color of the group
Not all nodes need to be in a sub network

Timeline

If no start or end date is specified, the data network is just shown as is. If there's a start or end date, the other CQLs need to have a @date parameter and that will be used to render the data network at a point in time.
You can use @date between [Modified] and [Replaced] with a version history query to see data at a point in time. You can also simply use @date > [Created] if it's an additive system.

Timeline Start Date

This CQL should return a date value as 'startDate'.

Timeline End Date

This CQL should return a date value as 'endDate'.

Slicers

To use slicers, you need to define the slicers in the [Slicers] column and add the additional attributes to the nodes query.
1
[
2
{
3
"attribute": "slice1",
4
"displayName": "First Slicer"
5
},
6
{
7
"attribute": "slice2",
8
"displayName": "Second Slicer"
9
}
10
]
Copied!
Attribute is the column name from the nodes query, displayName is what shows up in the visualizer.

System Tables

All the information above is entered into the [Cinchy].[Networks] table. To access the network, go to
<Cinchy URL>/Cinchy/apps/datanetworkvisualizer?network=<NAME>
Alternatively you can go to My Data Network and then add ?network=<NAME> to the end of it.
It is highly recommended to add a new applet for each custom data network visualizer for ease of access.

Example Network

For ease of testing, save the following as saved queries and then in the Networks table simply add exec [Domain].[Saved Query Name] as the CQLs.

Node Groups CQL

1
-- Sample Data
2
SELECT
3
[Sub Network] = 'Blue Network'
4
, [Color] = '#03a9f4'
5
INTO #TEMP
6
UNION SELECT
7
[Sub Network] = 'Green Network'
8
, [Color] = '#8bc34a'
9
-- Node Groups CQL
10
SELECT
11
t.[Sub Network] as 'sub network'
12
, t.[Color] as 'color'
13
FROM #TEMP t
Copied!

Nodes CQL

1
-- Sample Data
2
SELECT
3
[Id] = 'N01'
4
, [Title] = 'Hover text on the node.'
5
, [Label] = 'Purple Node 1 (Ax)'
6
, [Value] = 5
7
, [Mass] = 5
8
-- optional
9
, [Group] = 'Green Network'
10
, [Color] = '#ab47bc'
11
, [Description] = 'This description shows up in the top right hand corner when you select a node.'
12
, [Node URL] = 'https://www.cinchy.com'
13
, [Slicer 1] = 'A'
14
, [Slicer 2] = 'x'
15
INTO #TEMP
16
UNION SELECT
17
[Id] = 'N02'
18
, [Title] = 'Hover text on node 2.'
19
, [Label] = 'Node 2 (Ay)'
20
, [Value] = 10
21
, [Mass] = 10
22
-- optional
23
, [Group] = 'Green Network'
24
, [Color] = ''
25
, [Description] = 'This description shows up in the top right hand corner when you select a node.'
26
, [Node URL] = ''
27
, [Slicer 1] = 'A'
28
, [Slicer 2] = 'y'
29
UNION SELECT
30
[Id] = 'N03'
31
, [Title] = 'Hover text on node 3.'
32
, [Label] = 'Node 3 (Bx)'
33
, [Value] = 1
34
, [Mass] = 1
35
-- optional
36
, [Group] = 'Blue Network'
37
, [Color] = ''
38
, [Description] = ''
39
, [Node URL] = ''
40
, [Slicer 1] = 'B'
41
, [Slicer 2] = 'x'
42
UNION SELECT
43
[Id] = 'N04'
44
, [Title] = 'Hover text on node 4.'
45
, [Label] = 'Minimum Node 4 (y)'
46
, [Value] = 3
47
, [Mass] = 3
48
-- optional
49
, [Group] = ''
50
, [Color] = ''
51
, [Description] = ''
52
, [Node URL] = ''
53
, [Slicer 1] = ''
54
, [Slicer 2] = 'y'
55
UNION SELECT
56
[Id] = 'N05'
57
, [Title] = 'Hover text on node 4.'
58
, [Label] = 'Orphan Node 5 (By)'
59
, [Value] = 2
60
, [Mass] = 2
61
-- optional
62
, [Group] = ''
63
, [Color] = ''
64
, [Description] = ''
65
, [Node URL] = ''
66
, [Slicer 1] = 'B'
67
, [Slicer 2] = 'y'
68
-- Nodes CQL
69
SELECT
70
t.[Id] as 'id'
71
, t.[Title] as 'title'
72
, t.[Label] as 'label'
73
, t.[Value] as 'value'
74
, t.[Mass] as 'mass'
75
, t.[Group] as 'group'
76
, t.[Color] as 'color'
77
, t.[Description] as 'description'
78
, t.[Node URL] as 'nodeURL'
79
, t.[Slicer 1] as 'slice1'
80
, t.[Slicer 2] as 'slice2'
81
FROM #TEMP t
Copied!

Edges CQL

1
-- Sample Data
2
SELECT
3
[Id] = 'E01'
4
, [Label] = 'Node 1 to Node 2, Double Arrows'
5
, [From] = 'N01'
6
, [To] = 'N02'
7
-- optional
8
, [Show Arrow To] = 'True'
9
, [Show Arrow From] = 'True'
10
INTO #TEMP
11
UNION SELECT
12
[Id] = 'E02'
13
, [Label] = 'Node 2 to Node 3, To Arrow'
14
, [From] = 'N02'
15
, [To] = 'N03'
16
-- optional
17
, [Show Arrow To] = 'True'
18
, [Show Arrow From] = 'False'
19
UNION SELECT
20
[Id] = 'E03'
21
, [Label] = 'Node 1 to Node 4, From Arrow'
22
, [From] = 'N01'
23
, [To] = 'N04'
24
-- optional
25
, [Show Arrow To] = ''
26
, [Show Arrow From] = 'True'
27
UNION SELECT
28
[Id] = 'E04'
29
, [Label] = 'Node 3 to Node 3, No Arrow'
30
, [From] = 'N03'
31
, [To] = 'N03'
32
-- optional
33
, [Show Arrow To] = ''
34
, [Show Arrow From] = ''
35
36
-- Edges CQL
37
SELECT
38
t.[Id] as 'id'
39
, t.[Label] as 'label'
40
, t.[From] as 'from'
41
, t.[To] as 'to'
42
, t.[Show Arrow To] as 'showArrowTo'
43
, t.[Show Arrow From] as 'showArrowFrom'
44
FROM #TEMP t
Copied!
Last modified 1yr ago