channel(ch)

Read(134) Label: return a channel,

Description:

Create a channel and push data in another channel into it.

Syntax:

channel(ch)

 

Note:

The function creates a channel, pushes data in channel ch into it, and returns a channel. This is equivalent to ch.push(channel()).

Parameters:

ch

A channel

Return value:

A channel

Example:

 

A

 

1

=demo.cursor("select * from SCORES where CLASS = 'Class one'")

 

2

=channel()

Create a channel

3

=channel(A2)

Create a channel  and be ready to push data in A2’s channel into the new channel, which is equivalent to =A2.push(channel())

4

>A2.select(STUDENTID==1)

 

5

>A3.select(STUDENTID==2)

 

6

=A2.fetch()

 

7

=A3.fetch()

 

8

=A1.push(A2)

 

9

=A1.fetch()

 

10

=A2.result()

11

=A3.result()