Skip to content

Commit c62b4e0

Browse files
committed
Remove copyable
1 parent 7a50ce6 commit c62b4e0

File tree

1 file changed

+0
-14
lines changed

1 file changed

+0
-14
lines changed

functions-and-operators/tidb-functions.md

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,6 @@ This section provides examples for some of the functions above.
5353

5454
In the following example, the table `t1` has a hidden `rowid` that is generated by TiDB. The `TIDB_DECODE_KEY` is used in the statement. From the result, you can see that the hidden `rowid` is decoded and output, which is a typical result for the non-clustered primary key.
5555

56-
{{< copyable "sql" >}}
57-
5856
```sql
5957
SELECT START_KEY, TIDB_DECODE_KEY(START_KEY) FROM information_schema.tikv_region_status WHERE table_name='t1' AND REGION_ID=2\G
6058
```
@@ -68,8 +66,6 @@ TIDB_DECODE_KEY(START_KEY): {"_tidb_rowid":1958897,"table_id":"59"}
6866

6967
In the following example, the table `t2` has a compound clustered primary key. From the JSON output, you can see a `handle` that contains the name and value for both of the columns that are part of the primary key.
7068

71-
{{< copyable "sql" >}}
72-
7369
```sql
7470
show create table t2\G
7571
```
@@ -86,8 +82,6 @@ Create Table: CREATE TABLE `t2` (
8682
1 row in set (0.001 sec)
8783
```
8884

89-
{{< copyable "sql" >}}
90-
9185
```sql
9286
select * from information_schema.tikv_region_status where table_name='t2' limit 1\G
9387
```
@@ -114,8 +108,6 @@ REPLICATIONSTATUS_STATEID: NULL
114108
1 row in set (0.005 sec)
115109
```
116110

117-
{{< copyable "sql" >}}
118-
119111
```sql
120112
select tidb_decode_key('7480000000000000FF3E5F720400000000FF0000000601633430FF3338646232FF2D64FF3531632D3131FF65FF622D386337352DFFFF3830653635303138FFFF61396265000000FF00FB000000000000F9');
121113
```
@@ -232,8 +224,6 @@ This function returns a string, which is in the format of a JSON string array. T
232224
> * This function has a high overhead. In queries with a large number of rows (for example, querying the full table of `information_schema.cluster_tidb_trx` on a large and busy cluster), using this function might cause the queries to run for too long. Use it with caution.
233225
> * This function has a high overhead because every time it is called, it internally queries the `STATEMENTS_SUMMARY`, `STATEMENTS_SUMMARY_HISTORY`, `CLUSTER_STATEMENTS_SUMMARY`, and `CLUSTER_STATEMENTS_SUMMARY_HISTORY` tables, and the query involves the `UNION` operation. This function currently does not support vectorization, that is, when calling this function for multiple rows of data, the above query is performed separately for each row.
234226
235-
{{< copyable "sql" >}}
236-
237227
```sql
238228
set @digests = '["e6f07d43b5c21db0fbb9a31feac2dc599787763393dd5acbfad80e247eb02ad5","38b03afa5debbdf0326a014dbe5012a62c51957f1982b3093e748460f8b00821","e5796985ccafe2f71126ed6c0ac939ffa015a8c0744a24b7aee6d587103fd2f7"]';
239229
@@ -303,8 +293,6 @@ The following example shows how to use the `TIDB_SHARD` function.
303293

304294
The following statement shows how to use the `TIDB_SHARD` function to calculate the SHARD value of `12373743746`:
305295

306-
{{< copyable "sql" >}}
307-
308296
```sql
309297
SELECT TIDB_SHARD(12373743746);
310298
```
@@ -322,8 +310,6 @@ The following example shows how to use the `TIDB_SHARD` function.
322310

323311
- Create a shard index using the `TIDB_SHARD` function:
324312

325-
{{< copyable "sql" >}}
326-
327313
```sql
328314
CREATE TABLE test(id INT PRIMARY KEY CLUSTERED, a INT, b INT, UNIQUE KEY uk((tidb_shard(a)), a));
329315
```

0 commit comments

Comments
 (0)