Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Learning new SQL Tricks

Status
Not open for further replies.

PeteAmsterdam

Programmer
Jun 3, 2005
76
US
I have a customer master file (CM) that contains a subset of records I culled from the production file. I would now like to copy every detail record from a production order file to a duplicate test file for which the customer number exists in CM. Here is what I've attempted so far. Actually, this is the last attempt of a dozen or so
tries:

INSERT INTO DJLIB/CUSSN
SELECT * FROM DJLIB/CUSMAS, PRODLIB1/CUSSN WITH NC
WHERE CUSMAS.CSC# = CUSSN.SNC#

This generates that there is a problem w/ my use of "WHERE"

Any ideas would be greatly appreciated.

 
Is this for a SQL Server or another platform?

Denny
MCSA (2003) / MCDBA (SQL 2000)

--Anything is possible. All it takes is a little research. (Me)

[noevil]
(Not quite so old any more.)
 
I'm guessing that you aren't using SQL Server as that isn't correct syntax. There isn't any WITH NC in SQL Server's TSQL.

I suggest you post in an appropriate forum as this forum is specifically for Microsoft's SQL Server.

-SQLBill

Posting advice: FAQ481-4875
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top