Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


SQL Query

 
Logged in as: Guest
arrSession:exec spGetSession 2,7,40053
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [General Forum] >> Other Programming/Scripting Languages >> SQL Query
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 SQL Query - 11/24/2006 1:38:34 AM   
  tbraga

 

Posts: 41
Score: 0
Joined: 2/1/2006
Status: offline
Hi All,

I seem to be getting confused on this statement.  We recently installed integrator software to synchronize a few of our databases, I configured the application, setup all the DSN's, and the mapping.  Currently the job runs without errors but when I run it twice it places duplicates into the target table, obviously because there is not a where clause.  I was thinking of a couple of things but was not sure how to go about it, syntax, code structure ect...

I was thinking of using something like this to verify in the target table if the record already exists, but then again about not sure where to put this or which variables I need to declare:
      where not in (Select [Last Name], [StartDate]  from [_Customer_])    

Here is the mapping code from the Integrator Software:

Sub mapData()
               
    'targetRow("TargetColumn") = sourceRow("SourceColumn")
    targetRow("First Name") = sourceRow("FirstName")
    targetRow("Last Name") = sourceRow("LastName") 
    targetRow("EMail Address") = sourceRow("EMAIL")
    targetRow("Title") = sourceRow("JbcLongDesc")
    targetRow("StartDate") = sourceRow("EecDateOfLastHire")
    targetRow("TermDate") = sourceRow("EecDateOfTermination")
    targetRow("ClientText01") = sourceRow("MgrName")

End Sub
 
 
Post #: 1
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [General Forum] >> Other Programming/Scripting Languages >> SQL Query Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts