Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Characters indent not correctly always. #1400

Closed
Shylock-Hg opened this issue Dec 9, 2019 · 4 comments
Closed

Characters indent not correctly always. #1400

Shylock-Hg opened this issue Dec 9, 2019 · 4 comments
Assignees

Comments

@Shylock-Hg
Copy link
Contributor

Shylock-Hg commented Dec 9, 2019

Describe the bug(must be provided)
The table output not indent correctly if contains wide-size characters.

(user@127.0.0.1) [test]> fetch prop on building uuid('pin_测试') yield building.name
=================
| building.name |
=================
| 测试        |
-----------------
Got 1 rows (Time spent: 6454/7737 us)

Your Environments(must be provided)

  • OS: Linux hp-server 4.18.16-300.fc29.x86_64 Parser framework #1 SMP Sat Oct 20 23:24:08 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

  • Compliler:
    g++ (GCC) 8.2.0
    Copyright (C) 2018 Free Software Foundation, Inc.
    This is free software; see the source for copying conditions. There is NO
    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

  • CPU:
    Architecture: x86_64
    CPU op-mode(s): 32-bit, 64-bit
    Byte Order: Little Endian
    CPU(s): 40
    On-line CPU(s) list: 0-39
    Thread(s) per core: 2
    Core(s) per socket: 10
    Socket(s): 2
    NUMA node(s): 2
    Vendor ID: GenuineIntel
    CPU family: 6
    Model: 62
    Model name: Intel(R) Xeon(R) CPU E5-2690 v2 @ 3.00GHz
    Stepping: 4
    CPU MHz: 1629.598
    CPU max MHz: 3600.0000
    CPU min MHz: 1200.0000
    BogoMIPS: 5985.55
    Virtualization: VT-x
    L1d cache: 32K
    L1i cache: 32K
    L2 cache: 256K
    L3 cache: 25600K
    NUMA node0 CPU(s): 0-9,20-29
    NUMA node1 CPU(s): 10-19,30-39
    Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm cpuid_fault epb pti ssbd ibrs ibpb stibp tpr_shadow vnmi flexpriority ept vpid fsgsbase smep erms xsaveopt dtherm ida arat pln pts flush_l1d

How To Reproduce(must be provided)
Steps to reproduce the behavior:
Fetch the result contains wide-size characters.

Expected behavior
Indent correctly based on characters instead of bytes.

Additional context
Maybe we need support the inner encoding format for characters such as utf-8, ANSI etc.

@Amber1990Zhang
Copy link
Contributor

I'm suffering from the same issue. I guess this is caused by the Chinese characters in the query.

@Amber1990Zhang
Copy link
Contributor

GO FROM 1 OVER visit YIELD visit._dst AS id | \
GO FROM $-.id OVER work REVERSELY YIELD $$.person.name AS Name
==========
| Name   |
==========
| 小绿 |
----------
| 小蓝 |
----------

@Amber1990Zhang
Copy link
Contributor

GO FROM 18 OVER touch REVERSELY YIELD $$.person.name
==================
| $$.person.name |
==================
| 小明         |
------------------

FIND ALL PATH FROM 1 to 18 OVER touch UPTO 2 STEPS
============================
| _path_ |
============================
| 1 <touch,0> 18
----------------------------

@Amber1990Zhang
Copy link
Contributor

GO FROM 1 OVER visit YIELD $$.place.name AS Place
=========================
| Place                 |
=========================
| 洛阳龙门某民宿 |
-------------------------
| 洛阳白马寺       |
-------------------------
| 洛阳龙门石窟    |
-------------------------
| 济南趵突泉       |
-------------------------
| 济南某酒店       |
-------------------------
| 天津某药房       |
-------------------------
| 天津瓷房子       |
-------------------------
| 天津古文化街    |
-------------------------
| 天津某百货大楼 |
-------------------------
| 锦州                |
-------------------------

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants