Link to home
Start Free TrialLog in
Avatar of desiredforsome
desiredforsome

asked on

SQL QUery Error string or binary data would be truncated

Here is my query -
INSERT	OUTLOOKREPORT.DBO.loanselect
(	Borrower
,	[address]
,	[status]
,	xrefid
)
SELECT	a.BorrowerFirstName + ' ' + a.BorrowerLastname
,	a.Address1
,	a.CurrentMileStoneName
,	a.xrefid
FROM	emdb.emdbuser.loansummary	a
LEFT
JOIN	OUTLOOKREPORT.DBO.loanselect	b	ON	a.XREFID = b.XREFID
WHERE	b.XREFID IS NULL

--Inserts xrefid from Encompass into Interface
INSERT	OUTLOOKREPORT.DBO.xrefidtable
(	xrefid
)
SELECT		a.xrefid
FROM	emdb.emdbuser.loansummary	a
LEFT
JOIN	OUTLOOKREPORT.DBO.xrefidtable	b	ON	a.XREFID = b.XREFID
WHERE	b.XREFID IS NULL

Open in new window


Here is what it is outputting and I cant find my error.

Msg 8152, Level 16, State 4, Line 1
String or binary data would be truncated.
The statement has been terminated.

(0 row(s) affected)

Open in new window

SOLUTION
Avatar of brasso_42
brasso_42

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Avatar of Jim Horn
Jim Horn
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of desiredforsome
desiredforsome

ASKER

I haveth seen thy problem thansk to you all. Indeed you cannot fit US in the UK. increased NVARCHAR to 100 from 50 as the other table was 100.

Thanks!!!