3
IM具有使用的问题在“中”在本地查询,其中,在自变量是通过钻出一个excel列表中检索一个列表操作符:电源查询 - 在本地查询列表值
let
var = Number.ToText(fnFuncao("externalcode")),
Coluna= Excel.CurrentWorkbook(){[Name="Pendente"]}[Content],
#"Changed Type" = Table.TransformColumnTypes(Coluna,{{"PARAMETER", Int64.Type}, {"INTERACTION_ID", Int64.Type}, {"INTERACTION_ITEM", Int64.Type}}),
INTERACTION_ID = #"Changed Type"[INTERACTION_ID][0],
Source = Oracle.Database("somp", [Query="select * from ish.ticket where interaction_id in (" & INTERACTION_ID & ") "])
in
Source
Error:
Expression.Error: We cannot apply operator & to types Text and List.
Details:
Operator=&
Left=select * from ish.ticket where interaction_id in (
Right=List
不限如何解决这个问题? 谢谢!
太棒了。有效!谢谢 ! – user3682983
如果我的interaction_id列在单元格a1,b1,c1中有值,该怎么办?有没有办法在查询中包含所有的值? – user3682983
删除INTERACTION_ID步骤并将其用于查询: ''select * from ish.ticket其中interaction_id in(“&List.Accumulate(List.Skip(#”Changed Type“[INTERACTION_ID],1),Number.ToText (#“Changed Type”[INTERACTION_ID] {0}),(state,current)=> state&“,”&Number.ToText(current))&“)”' 这循环遍历列并在第一个元素。这只有在列中有值的情况下才有效。 –