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

Fix convert numbers to strings #465

Merged
merged 4 commits into from
May 23, 2023
Merged

Fix convert numbers to strings #465

merged 4 commits into from
May 23, 2023

Conversation

liuxiaocs7
Copy link
Member

fix data type transfer when number in database but declare as text(string) in schema.

eg:

29         ->     "29"
199.67     ->     "199.67"

result(metrics log):

>> HugeGraphLoader worked in NORMAL MODE
vertices/edges loaded this time : 8/0
--------------------------------------------------
count metrics
    input read success            : 8                   
    input read failure            : 0                   
    vertex parse success          : 8                   
    vertex parse failure          : 0                   
    vertex insert success         : 8                   
    vertex insert failure         : 0                   
    edge parse success            : 0                   
    edge parse failure            : 0                   
    edge insert success           : 0                   
    edge insert failure           : 0                   
--------------------------------------------------
meter metrics
    total time                    : 0.062s              
    read time                     : 0.036s              
    load time                     : 0.026s              
    vertex load time              : 0.026s              
    vertex load rate(vertices/s)  : 307                 
    edge load time                : 0s                  
    edge load rate(edges/s)       : -1   

Local UTs:

Snipaste_2023-05-18_02-26-59

@codecov
Copy link

codecov bot commented May 17, 2023

Codecov Report

Merging #465 (7b059ac) into master (44a0818) will decrease coverage by 0.01%.
The diff coverage is 40.00%.

@@             Coverage Diff              @@
##             master     #465      +/-   ##
============================================
- Coverage     62.51%   62.50%   -0.01%     
- Complexity      894     1868     +974     
============================================
  Files            91      260     +169     
  Lines          4396     9429    +5033     
  Branches        516      875     +359     
============================================
+ Hits           2748     5894    +3146     
- Misses         1445     3151    +1706     
- Partials        203      384     +181     
Impacted Files Coverage Δ
.../apache/hugegraph/structure/constant/DataType.java 61.53% <0.00%> (ø)
...org/apache/hugegraph/loader/util/DataTypeUtil.java 70.13% <50.00%> (-0.79%) ⬇️

... and 168 files with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@imbajin imbajin requested a review from javeme May 18, 2023 11:14
Copy link
Member

@imbajin imbajin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@javeme javeme merged commit f0cbdbc into apache:master May 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

[Bug] The target data type must be number
5 participants