[英]Operand type clash: uniqueidentifier is incompatible with int in query
When I attempt to use query I get the following error: 当我尝试使用查询时,出现以下错误:
Operand type clash: uniqueidentifier is incompatible with int
操作数类型冲突:uniqueidentifier与int不兼容
Query: 查询:
insert into [D:\BACKUP1\ADBASE\APP_DATA\SCIENCECOM.MDF].dbo.Surfaces
(Height, Width, Space, Id)
select
'0' as Name,
'0' as Width,
'0' as Space,
[D:\BACKUP1\ADBASE\APP_DATA\SCIENCECOM.MDF].dbo.Sides.Id
from [D:\BACKUP1\ADBASE\APP_DATA\SCIENCECOM.MDF].dbo.Sides
Can someone tell me what I've done wrong? 有人可以告诉我我做错了什么吗?
如果您的Id列被声明为uniqueidentifier
,则它可能会自动生成,因此,如果我正确理解了您的问题,则无法通过查询手动插入...。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.