Hi expert wants to match data between two table or not
"To be or not to be".
Your post is very unclear, the "SQL code" is hard to read and the logic for "expected output" is missing.
Please post the missing details and remove unrelated tags.
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Hi expert wants to match data between two table or not Create table table1(col varchar (20)) Create table table2(col varchar(20)) Insert into table1 values (20) Insert into table2 values (20) Insert into table1 values ('test') Insert into table2 values ('test1') Expected output Output1 ='row 2 data missmatch' Scenario 2 Create table table1(col varchar (20)) Create table table2(col varchar(20)) Insert into table1 values (20) Insert into table2 values (20) Insert into table1 values ('test') Insert into table2 values ('test') Expected output ='output matched'
Hi expert wants to match data between two table or not
"To be or not to be".
Your post is very unclear, the "SQL code" is hard to read and the logic for "expected output" is missing.
Please post the missing details and remove unrelated tags.
first:
Create table table1(col bar chart (20))
is not valid syntax
second, your insert mix number and string for the same column. also an error.
third, you appear to want to match on row number, but sql table rows do not have a row number, without an order by clause the order is undefined. you need to add insert order column.
if you don't care about the order then just use left and right joins