data-diff icon indicating copy to clipboard operation
data-diff copied to clipboard

Support Integer value in String Column Type primary key

Open imfaridz opened this issue 1 year ago • 2 comments

Hi,

I encounter that every time I pass string column type as a primary key to TableSegment, it will throws this error

NotImplementedError: Cannot use column of type Text() as a key

However, the values inside the column is actually Integer. Can data-diff support this kind of issue ?

Thanks !

imfaridz avatar Aug 05 '22 02:08 imfaridz

I think of a solution like casting the column type to integer when querying the table, but wanna knows other thought about this. Happy to help create a PR if needed :)

imfaridz avatar Aug 05 '22 02:08 imfaridz

Can you please try the latest master version? I think it has a fix for this issue.

You can install it with

pip install git+https://github.com/datafold/data-diff.git

erezsh avatar Aug 05 '22 07:08 erezsh