跨服务器查询在SQL Server 2008R2中不起作用(Cross-server query does not work in SQL Server 2008R2)
我已经了解了如何进行跨服务器查询:
serverName.DBName.SchemaName.TableName
我这样做,我得到一个错误告诉我在sys.servers上找不到服务器。 我查询了sys.servers,但我只看到了自己的服务器名称而没有别的。
- 我错过了什么? 错误消息还为我提供了存储过程的名称。 但我只是不确定为什么这不起作用,它不应该工作得很好?? 我确实有BOTH服务器上的凭据/权限来读写。 所以我不认为这是一个许可的事情。
错误信息:
无法在sys.servers中找到服务器“targetServerName”。 验证是否指定了正确的服务器名称。 如有必要,执行存储过程sp_addlinkedserver以将服务器添加到sys.servers。
I've read up on how to do a cross-server query:
serverName.DBName.SchemaName.TableName
I do just this and I get an error telling me that the server is not found on sys.servers. I queried sys.servers but I just see my own server's name and nothing else.
--Am I missing something? The error message also gives me a stored procedure's name. But I am just not sure why this is not working, shouldn't it be working just fine?? I do have credentials/permissions on BOTH servers to read and write. So I don't think it's a permission thing.
Error message:
Could not find server 'targetServerName' in sys.servers. Verify that the correct server name was specified. If necessary, execute the stored procedure sp_addlinkedserver to add the server to sys.servers.
原文:https://stackoverflow.com/questions/30598834
最满意答案
你可以使用类似的东西
which(x %in% NA)
,其中x
是传递给ggplot2
的数据。例如,
x <- c(1,2,NA,4,4,NA) which(x %in% NA)
返回
[1] 3 6
和which(x %in% 4)
返回
[1] 4 5
You could use something like,
which(x %in% NA)
wherex
is your data passed toggplot2
.For example,
x <- c(1,2,NA,4,4,NA) which(x %in% NA)
returns
[1] 3 6
andwhich(x %in% 4)
returns
[1] 4 5
相关问答
更多-
您可以使用ggsave()保存最后一个绘图并调整用于点/线等的缩放因子。试试这个: ggplot(data = ch2) + geom_polygon(aes(x=long, y=lat, group=group), colour="grey85", fill="grey90") + geom_point(data=datmap, aes(x=E, y=N, group=FALSE, size=n), color=c("red"), alph ...
-
R - 在geom_boxplot(ggplot2)之上绘制geom_point(R - plotting geom_point on top of geom_boxplot (ggplot2))[2023-09-02]
geom_point()应该使用color属性,而不是fill属性(除非你使用不寻常的shape )。 看看这是否适合你: meansPlot = ggplot(data=meansData,aes(x=factor(name), y=volume, fill=factor(genotype)), color = factor(genotype)) meansPlot = meansPlot + geom_boxplot() + geom_point() + facet_wrap( ~ region, s ... -
你可以使用类似的东西which(x %in% NA) ,其中x是传递给ggplot2的数据。 例如, x <- c(1,2,NA,4,4,NA) which(x %in% NA) 返回[1] 3 6和 which(x %in% 4) 返回[1] 4 5 You could use something like, which(x %in% NA) where x is your data passed to ggplot2. For example, x <- c(1,2,NA,4,4,NA) which ...
-
更改ggplot geom_point中某些中断值的alpha值(Change alpha value for certain break values in ggplot geom_point)[2020-01-08]
一种策略是使用cut将四分位数分成三组。 然后你可以使用scale_colour_manual # some fake data plotintaobs <- data.frame(SD13009PB = rnorm(20), SD13009PB2 = rnorm(20), quartile = 1:20) #cut quartile plotintaobs$q2 <- cut(plotintaobs$quartile, breaks = c(0, 2, 19, 20), labels = c("low ... -
如何从ggplot2包中仅绘制geom_point中的一系列值?(How to draw only a range of values in geom_point from the ggplot2 package?)[2020-02-02]
我不确定这是否是您正在寻找的内容,但在绘制点时忽略零值的一种方法是将您的geom_point()语句修改为 geom_point(subset = .(value > 0)) 该行只传递要绘制的数据帧中的非零值。 i am not sure if this is what you are looking for, but one approach to ignore the zero values while plotting the points is to modify your geom_point ... -
你可以制作shape = Serie整个绘图的美学系列,然后使用scale_shape ,其中“Original”的形状是NA并且不绘制。 ggplot(base_fin, aes(x = fecha, y = valor, shape = Serie)) + geom_line(aes(colour = Serie, linetype= Serie, size = Serie)) + facet_wrap(~ indicador_f, scales = "free") + theme_b ...
-
你快到了! 这只是'切割'因素的名称是不正确的。 如果你试试: cut(test$TC1, c(-Inf, 1000, 5000, 50000, Inf)) # [1] (-Inf,1e+03] (1e+03,5e+03] (-Inf,1e+03] (-Inf,1e+03] (-Inf,1e+03] # [6] (-Inf,1e+03] (-Inf,1e+03] (5e+03,5e+04] (5e+04, Inf]
# Levels: (-Inf,1e+03] ... -
那是因为scales::shape_pal定义了最多6个值; 尝试添加scale_shape_manual(values=1:7) That's because scales::shape_pal defines a maximum of 6 values; try adding scale_shape_manual(values=1:7)
-
逐个运行代码我们可以很容易地发现scale_shape_manual是罪魁祸首,在此之前的所有内容都可以找到。 (如果你做了一个最小的例子,你很容易发现...) 你告诉ggplot所有形状geom_point应该是Gp2 ,这是你映射的第二个形状。 因此,它将查看values中的第二个条目,并发现存在NA 。 所以你自己告诉ggplot它应该给所有点的NA形状。 (请注意,您在geom_bar映射了形状Gp1 ,但是geom_bar没有采用那种美学......) Running your code piec ...
-
使用ggplot2 geom_tile()+ geom_point()突出显示切片(Highlight tiles with ggplot2 geom_tile() + geom_point())[2022-01-27]
首先,您不需要在数据input_ddg T和F替换为TRUE和FALSE值。 接下来,列pg9_seq_bool可以直接在geom_point() aes()中geom_point() 。 这将根据TRUE / FALSE值产生两种类型的点。 然后使用scale_size_manual()将大小0设置为FALSE,将6设置为TRUE。 如果此点大小不应出现在图例中,则在scale_size_maual()添加参数guide="none" 。 ggplot(input_ddg, aes(residue_id, ...