termsql icon indicating copy to clipboard operation
termsql copied to clipboard

Merge tables

Open efratushava opened this issue 4 years ago • 2 comments

Hi, Can I somehow merge two tables together?

Thank you

efratushava avatar Aug 05 '20 08:08 efratushava

If they contain compatible data, that shouldn't be a problem.

Have you read the manual? http://tobimensch.github.io/termsql/

I think the -a option for not dropping the tables should be interesting for you.

The -o option for writing the database to a file should be equally interesting to you.

Now try to combine those two and you should be able to create a permanent database where you can add data as you wish, with termsql, but also other tools.

If you mean merging data that is only partially compatible, then I think there's no support for that.

tobimensch avatar Aug 05 '20 10:08 tobimensch

Hi, Assume we have two tables R1 and R2 with the following schemas: R1(A1, A2) R2(A2, A3) Is it possible to join R1 and R2 using termsql ? in SQL I achieve it using the following query: SELECT * FROM R1, R2 WHERE R1.A2 = R2.A2

thanks in advance!

ayoubfalah avatar Jul 31 '23 10:07 ayoubfalah