April 8, 2009 at 7:55 am
Jeff Moden (4/7/2009)
I've not read all the posts on this thread, but why not just use replication for this?
Hi jeff, this is not about replication.:-D Its about moving data from one table to another. The criteria is move only the records which are not there in the destination table. As part of this this process he want to convert the data type from Int to Varchar. 🙂
By looking at the replies i think he got the answer 🙂
April 8, 2009 at 5:51 pm
Vijaya Kadiyala (4/8/2009)
Jeff Moden (4/7/2009)
I've not read all the posts on this thread, but why not just use replication for this?
Hi jeff, this is not about replication.:-D Its about moving data from one table to another. The criteria is move only the records which are not there in the destination table. As part of this this process he want to convert the data type from Int to Varchar. 🙂
By looking at the replies i think he got the answer 🙂
Indeed, I got the answer I was looking for. My aplogies for brniging up a different subject under the same topic.
April 9, 2009 at 2:20 am
AFIFM (4/7/2009)
I have to ask, what are you going to do when you find out that they're equal or not?
I was trying to find which records in table A that not in table B so I can copy those to table B.
You can try
Select ... from a
except
select ... from b
that gives you all rows from table a that are not in table b
April 9, 2009 at 7:50 am
ulile (4/9/2009)
AFIFM (4/7/2009)
Select ... from a
except
select ... from b
that gives you all rows from table a that are not in table b
From query prespective how is this different than NOT EXISTS clause!!! which is better?
April 14, 2009 at 12:15 am
The except-clause requires that both parts of the sql-statement have the same structure. The exist-clause needs a subquery to work. Which is faster (or better) I don't no.
April 14, 2009 at 4:54 am
By looking at the exeuction plan i believe EXISTS is faster...
Viewing 6 posts - 16 through 20 (of 20 total)
You must be logged in to reply to this topic. Login to reply