@@ -51,9 +51,10 @@ For usage as a library, please refer to the [godoc](https://pkg.go.dev/github.co
51
51
* 4.12. [ YAML] ( #yaml )
52
52
* 4.13. [ TBLN] ( #tbln )
53
53
* 4.14. [ WIDTH] ( #width )
54
- * 4.15. [ Raw output] ( #raw-output )
55
- * 4.16. [ ASCII Table & MarkDown output] ( #ascii-table-&-markdown-output )
56
- * 4.17. [ Vertical format output] ( #vertical-format-output )
54
+ * 4.15. [ TEXT] ( #text )
55
+ * 4.16. [ Raw output] ( #raw-output )
56
+ * 4.17. [ ASCII Table & MarkDown output] ( #ascii-table-&-markdown-output )
57
+ * 4.18. [ Vertical format output] ( #vertical-format-output )
57
58
* 5 . [ SQL] ( #sql )
58
59
* 5.1. [ SQL function] ( #sql-function )
59
60
* 5.2. [ JOIN] ( #join )
@@ -185,6 +186,7 @@ trdsql -o[output format] -t [input filename]
185
186
* ` -iyaml ` YAML format for input.
186
187
* ` -itbln ` TBLN format for input.
187
188
* ` -iwidth ` width specification format for input.
189
+ * ` -itext ` text format for input.
188
190
189
191
#### 3.2.1. <a name =' input-options ' ></a >Input options
190
192
@@ -193,6 +195,7 @@ trdsql -o[output format] -t [input filename]
193
195
* ` -ijq ` ** string** jq expression string for input(JSON/JSONL only).
194
196
* ` -ilr ` ** int** limited number of rows to read.
195
197
* ` -inull ` ** string** value(string) to convert to null on input.
198
+ * ` -inum ` add row number column.
196
199
* ` -ir ` ** int** number of rows to preread. (default 1)
197
200
* ` -is ` ** int** skip header row.
198
201
@@ -792,7 +795,40 @@ But `-id " "` does not recognize spaces in columns very well.
792
795
793
796
` -iwidth ` recognizes column widths and space separators.
794
797
795
- ### 4.15. <a name =' raw-output ' ></a >Raw output
798
+ ### 4.15. <a name =' text ' ></a >TEXT
799
+
800
+ The ` -itext ` option or files with “.text”extension are in text format.
801
+
802
+ This is a one line to one column format.
803
+ A blank line is also a line, unlike the ` CSV ` format.
804
+
805
+ ``` console
806
+ $ cat test.text
807
+ a
808
+
809
+ b
810
+
811
+ c
812
+ $ trdsql -itext " SELECT * FROM test.text"
813
+ a
814
+
815
+ b
816
+
817
+ c
818
+ ```
819
+
820
+ It is useful in conjunction with the -inum option.
821
+
822
+ ``` console
823
+ $ trdsql -inum " SELECT * FROM test.text"
824
+ 1,a
825
+ 2,
826
+ 3,b
827
+ 4,
828
+ 5,c
829
+ ```
830
+
831
+ ### 4.16. <a name =' raw-output ' ></a >Raw output
796
832
797
833
` -oraw ` is Raw Output.
798
834
It is used when "escape processing is unnecessary" in CSV output.
@@ -817,7 +853,7 @@ $ trdsql -oraw -od "\t|\t" -db pdb "SELECT * FROM test.csv"
817
853
3 | Apple
818
854
```
819
855
820
- ### 4.16 . <a name =' ascii-table-&-markdown-output ' ></a >ASCII Table & MarkDown output
856
+ ### 4.17 . <a name =' ascii-table-&-markdown-output ' ></a >ASCII Table & MarkDown output
821
857
822
858
` -oat ` is ASCII table output.
823
859
@@ -845,7 +881,7 @@ $ trdsql -omd "SELECT * FROM test.csv"
845
881
846
882
The ` -onowrap ` option does not wrap long columns in ` at ` or ` md ` output.
847
883
848
- ### 4.17 . <a name =' vertical-format-output ' ></a >Vertical format output
884
+ ### 4.18 . <a name =' vertical-format-output ' ></a >Vertical format output
849
885
850
886
-ovf is Vertical format output("column name | value" vertically).
851
887
0 commit comments