If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Data Access, Manipulation & Batch Languages > Delphi, C etc > I've hit the wall

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 05-16-02, 21:14
Smiley1 Smiley1 is offline
Junior Member
 
Join Date: May 2002
Posts: 17
I've hit the wall

Re the table comparisons,
My code now looks like this

' What the record was
MyDb.Execute _
("select CQ2.* INTO Temp " _
& "From CQ2 Where Not Exists " _
& "(select * from [Contractor Qualified] as CQ where " _
& "((CQ2.Area = CQ.Area) and " _
& "(CQ2.[Trade Type] = CQ.[Trade Type]) and " _
& "(CQ2.[Rate Above Par] = CQ.[Rate Above Par]) and " _
& "(CQ2.[Contractor Id] = CQ.[Contractor Id])))")

'What the record is
MyDb.Execute _
("insert into Temp select [Contractor Qualified].* " _
& "From [Contractor Qualified] Where Not Exists " _
& "(select * from CQ2 where " _
& "((CQ2.Area = [Contractor Qualified].Area) and " _
& "(CQ2.[Trade Type] = [Contractor Qualified].[Trade Type]) and " _
& "(CQ2.[Rate Above Par] = [Contractor Qualified].[Rate Above Par]) and " _
& "(CQ2.[Contractor Id] = [Contractor Qualified].[Contractor Id])))")

This shows any changes to the records as well as any new ones added. I need to filter this so that the new records go into a permanent backup table and the changed records go to a transaction changed table. Any suggestions

Many Thanks
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On