Skip to content

datafusion-cli cursor isn't on the right position in windows 7 cmd #9501

Closed

Description

@l1t1

Describe the bug

use pageup key to get the history command,
if I move the cursor to the left position of g and press (, it insert the ( after g

❯ select g(enerate_series(1,10);

To Reproduce

datafusion-cli

input

select g(enerate_series(1,10);
+-------------------------------------+
| generate_series(Int64(1),Int64(10)) |
+-------------------------------------+
| [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]     |
+-------------------------------------+
```

then 
use pageup key to get the history command,
if I move the cursor to the left position of g and press `(`


### Expected behavior

insert `(` before g

### Additional context

_No response_

Activity

  1. added
    bugSomething isn't working
    on Mar 8, 2024
  2. l1t1 commented on Mar 13, 2024

    @l1t1
    Author

    maybe the root of the problem is the prompt ❯ is a utf-8 character, it occupied multi-bytes, suggest use an ASCII charactor, such as
    >

  3. l1t1 commented on Mar 13, 2024

    @l1t1
    Author

    this prompt displayed as a box in cmd of windows 7
    2024-03-13_082138

  4. alamb commented on Mar 18, 2024

    @alamb
    Contributor

    Thanks for the report @l1t1

    Maybe we could change the prompt character on windows (perhaps to >) ?

  5. alamb commented on Mar 18, 2024

    @alamb
    Contributor

    I think this is a good first issue for someone with a windows machine to test on

  6. colommar commented on Apr 10, 2024

    @colommar
    Contributor

    @alamb Hi! I have a windows machine and changed all those ❯ to >. Is this OK?
    And I wanna test if the change does work how can I rebuild the datafusion to update the change by using the command datafusion-cli

  7. alamb commented on Apr 10, 2024

    @alamb
    Contributor

    Great @colommar !

    To test the change locally you can do something like this

    cd datafusion/datafusion-cli
    cargo run
  8. colommar commented on Apr 10, 2024

    @colommar
    Contributor

    @l1t1 I guess it was fine now. Can you help me test it on your pc?

  9. l1t1 commented on Apr 10, 2024

    @l1t1
    Author

    could you attach the binary file?

  10. colommar commented on Apr 10, 2024

    @colommar
    Contributor

    could you attach the binary file?

    @l1t1 Sure! Is this OK? Does it help you?
    datafusion-cli.zip

  11. l1t1 commented on Apr 11, 2024

    @l1t1
    Author

    could you attach the binary file?

    @l1t1 Sure! Is this OK? Does it help you? datafusion-cli.zip

    it works, very thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueGood for newcomershelp wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions