postgresql - Excel + npgsql + postgres. Specified cast is not valid exception -
i'm trying connect ms excel 2013 pro+ postgresql db using power query , npgsql connector.
everything seems fine, until - i'll try run custom query (eg. select * table). - there's error message coming up: "the specified cas not valid". if i'll use db structure browser - i'm able select table or view , hit 'load' it's giving me same error.
is there wrong, or there bug in connector?
here's stacktrace excel:
feedback type: frown (error)
timestamp: 2017-08-21t09:14:00.7435203z
local time: 2017-08-21t11:14:00.7435203+02:00
product version: 2.48.4792.941 (pq-cy17su07) (x86)
release: july, 2017
excel version: 15.0.4420.1017
excel install location: c:\program files\microsoft office\office15\excel.exe
ie version: 11.0.9600.17843
os version: microsoft windows nt 6.1.7601 service pack 1 (x86 pl-pl)
clr version: 4.6.1 or later [release number = 394271]
workbook package info: 1* - en-us, query groups: 0, fastcombine: disabled, runbackgroundanalysis: true.
peak working set: 268 mb
private memory: 231 mb
peak virtual memory: 930 mb
error message: specified cast not valid.
stack trace: microsoft.mashup.evaluator.interface.errorexception: specified cast not valid. ---> microsoft.mashup.evaluator.interface.errorexception: specified cast not valid. ---> microsoft.mashup.evaluator.interface.errorexception: specified cast not valid. ---> system.invalidcastexception: specified cast not valid. ---> system.invalidcastexception: specified cast not valid. @ microsoft.oledb.serialization.pagewriter.writeschema(datatable schematable) @ microsoft.oledb.serialization.oledbpagewriter..ctor(stream stream, datatable schematable) @ microsoft.mashup.evaluator.remotepagereader.<>c__displayclass7.b__0() @ microsoft.mashup.evaluator.evaluationhost.reportexceptions(ihosttrace trace, ienginehost enginehost, imessagechannel channel, action action) --- end of inner exception stack trace --- @ microsoft.mashup.evaluator.evaluationhost.<>c__displayclass7.b__6() @ microsoft.mashup.common.safeexceptions.ignoresafeexceptions(ienginehost host, ihosttrace trace, action action) @ microsoft.mashup.evaluator.evaluationhost.tryreportexception(ihosttrace trace, ienginehost enginehost, imessagechannel channel, exception exception) @ microsoft.mashup.evaluator.evaluationhost.reportexceptions(ihosttrace trace, ienginehost enginehost, imessagechannel channel, action action) @ microsoft.mashup.evaluator.remotepagereader.runstub(ienginehost enginehost, imessagechannel channel, func1 getpagereader) @ microsoft.mashup.evaluator.remotedocumentevaluator.service.<>c__displayclass11.<onbegingetdatareadersource>b__f(evaluationresult21 result) @ microsoft.mashup.evaluator.remotedocumentevaluator.service.<>c__displayclass1e1.<onbegingetresult>b__1b() @ microsoft.mashup.evaluator.evaluationhost.reportexceptions(ihosttrace trace, ienginehost enginehost, imessagechannel channel, action action) @ microsoft.mashup.evaluator.remotedocumentevaluator.service.onbegingetresult[t](imessagechannel channel, begingetresultmessage message, action1 action) @ microsoft.mashup.evaluator.remotedocumentevaluator.service.onbegingetdatareadersource(imessagechannel channel, begingetdatareadersourcemessage message) @ microsoft.mashup.evaluator.messagehandlers.<>c__displayclassa1.<addhandler>b__8(imessagechannel channel, message message) @ microsoft.mashup.evaluator.messagehandlers.trydispatch(imessagechannel channel, message message) @ microsoft.mashup.evaluator.channelmessenger.channelmessagehandlers.trydispatch(imessagechannel channel, message message) @ microsoft.mashup.evaluator.messagehandlers.dispatch(imessagechannel channel, message message) @ microsoft.mashup.evaluator.channelmessenger.onmessagewithunknownchannel(imessagechannel basechannel, messagewithunknownchannel messagewithunknownchannel) @ microsoft.mashup.evaluator.messagehandlers.<>c__displayclassa1.b__8(imessagechannel channel, message message) @ microsoft.mashup.evaluator.messagehandlers.trydispatch(imessagechannel channel, message message) @ microsoft.mashup.evaluator.channelmessenger.channelmessagehandlers.trydispatch(imessagechannel channel, message message) @ microsoft.mashup.evaluator.messagehandlers.dispatch(imessagechannel channel, message message) @ microsoft.mashup.evaluator.evaluationhost.run() @ microsoft.mashup.container.evaluationcontainermain.run(object args) @ microsoft.mashup.evaluator.safethread2.<>c__displayclass2.b__0(object o) @ microsoft.mashup.evaluator.safethread2.<>c__displayclass15.b__14(object o) @ microsoft.mashup.evaluator.safethread2.<>c__displayclass2.b__1(object o) @ microsoft.mashup.container.evaluationcontainermain.saferun(string[] args) @ microsoft.mashup.container.evaluationcontainermain.main(string[] args) --- end of inner exception stack trace --- @ microsoft.mashup.evaluator.evaluationhost.onexception(ienginehost enginehost, imessagechannel channel, exceptionmessage message) @ microsoft.mashup.evaluator.remoteevaluationcontainerfactory.container.onexception(imessagechannel channel, exceptionmessage message) @ microsoft.mashup.evaluator.messagehandlers.<>c__displayclassa1.<addhandler>b__8(imessagechannel channel, message message) @ microsoft.mashup.evaluator.messagehandlers.trydispatch(imessagechannel channel, message message) @ microsoft.mashup.evaluator.messagehandlers.dispatch(imessagechannel channel, message message) @ microsoft.mashup.evaluator.channelmessenger.channelmessagehandlers.trydispatch(imessagechannel channel, message message) @ microsoft.mashup.evaluator.messagehandlers.dispatch(imessagechannel channel, message message) @ microsoft.mashup.evaluator.interface.imessagechannelextensions.waitfor[t](imessagechannel channel) @ microsoft.mashup.evaluator.messagebasedinputstream.readnextchunkandcheckifclosed() @ microsoft.mashup.evaluator.messagebasedinputstream.readnextchunk() @ microsoft.mashup.evaluator.chunkedinputstream.read(byte[] buffer, int32 offset, int32 count) @ system.io.binaryreader.fillbuffer(int32 numbytes) @ system.io.binaryreader.readint32() @ microsoft.mashup.evaluator.itablesourceserializationextensions.readitablesource(binaryreader reader) @ microsoft.mashup.evaluator.remotepagereader.createproxy(ienginehost enginehost, imessagechannel channel, exceptionhandler exceptionhandler) @ microsoft.mashup.evaluator.remotedocumentevaluator.datareadersourceremoteevaluation.getresult(boolean enablefirewall) @ microsoft.mashup.evaluator.remotedocumentevaluator.remoteevaluation.evaluate(boolean enablefirewall) --- end of inner exception stack trace --- @ microsoft.mashup.evaluator.remotedocumentevaluator.remoteevaluation1.trycompletewithexception(exception exception) @ microsoft.mashup.evaluator.remotedocumentevaluator.remoteevaluation.evaluate(boolean enablefirewall) @ microsoft.mashup.evaluator.remotedocumentevaluator.evaluationthread(object state) @ microsoft.mashup.evaluator.globalizedevaluatorthreadpool.<>c__displayclass4.b__3(object s) @ microsoft.mashup.evaluator.evaluatorthreadpool.evaluatorthread(object state) @ microsoft.mashup.evaluator.safethread2.<>c__displayclass2.b__0(object o) @ microsoft.mashup.evaluator.safethread2.<>c__displayclass15.b__14(object o) @ microsoft.mashup.evaluator.safethread2.<>c__displayclass2.b__1(object o) @ system.threading.threadhelper.threadstart_context(object state) @ system.threading.executioncontext.runinternal(executioncontext executioncontext, contextcallback callback, object state, boolean preservesyncctx) @ system.threading.executioncontext.run(executioncontext executioncontext, contextcallback callback, object state, boolean preservesyncctx) @ system.threading.executioncontext.run(executioncontext executioncontext, contextcallback callback, object state) @ system.threading.threadhelper.threadstart(object obj) --- end of inner exception stack trace ---
server stack trace:
exception rethrown @ [0]: @ microsoft.oledb.asyncresult1.get_value() @ microsoft.mashup.oledbprovider.datahost.bufferingmashupevaluator.bufferingmashupevaluation.getbufferedreadersource(asyncresult1 result) @ microsoft.mashup.oledbprovider.datahost.bufferingmashupevaluator.bufferingmashupevaluation.onevaluationcomplete(asyncresult`1 result)
exception rethrown @ [1]: @ microsoft.mashup.host.providershared.mashupresource.getstatus() @ microsoft.mashup.client.excel.fill.pollingfilldownloadworker.b__1() @ microsoft.mashup.client.excel.fill.pollingfilldownloadworker.invokeworker(func`1 action)
invocation stack trace: @ microsoft.mashup.host.document.exceptionextensions.getcurrentinvocationstacktrace() @ microsoft.mashup.client.clientshared.stacktraceinfo..ctor(string exceptionstacktrace, string invocationstacktrace) @ microsoft.mashup.client.clientshared.feedbackerrorinfo..ctor(string message, nullable1 errorcode, string requestid, exception exception) @ microsoft.mashup.client.clientshared.unexpectedexceptionhandler.<>c__displayclass1.<handleexception>b__0() @ microsoft.mashup.host.document.synchronizationcontextextensions.sendandmarshalexceptions(synchronizationcontext context, action callback) @ microsoft.mashup.client.clientshared.unexpectedexceptionhandler.handleexception(exception e) @ microsoft.mashup.client.excel.fill.fillsession.handledownloaderexception(iworkbook workbook, exception e) @ microsoft.mashup.client.excel.fill.pollinginitialfillsession.filldownloadresult(iworkbook workbook, boolean ontimer) @ microsoft.mashup.client.excel.fill.pollinginitialfillsession.<>c__displayclass4.<resumefill>b__0() @ microsoft.mashup.client.excel.fill.iundoservicesextensions.<>c__displayclass2.<invokewithconditionaldiscardedundoscope>b__0(iundoscope undoscope) @ microsoft.mashup.client.excel.shim.addinundoservices.invokeundoableaction(iworkbook workbook, undoableactiontype actiontype, action1 action) @ microsoft.mashup.client.excel.fill.iundoservicesextensions.invokewithconditionaldiscardedundoscope(iundoservices undoservices, boolean condition, iworkbook workbook, undoableactiontype actiontype, action action) @ microsoft.mashup.client.excel.fill.pollinginitialfillsession.resumefill(boolean ontimer) @ microsoft.mashup.client.excel.pollingfillmanager.b__7(ifillsession fillsession) @ microsoft.mashup.client.clientshared.model.queriesutilities.foreachwithchangescope[t](ienumerable1 items, func2 getqueries, action1 action) @ microsoft.mashup.client.excel.fill.fillmanager.foreachfillsessionbyworkbook(action1 action) @ microsoft.mashup.client.excel.pollingfillmanager.updatequeries() @ microsoft.mashup.client.excel.pollingfillmanager.b__6() @ microsoft.mashup.host.document.exceptionhandlerextensions.handleexceptions(iexceptionhandler exceptionhandler, action action) @ microsoft.mashup.client.excel.pollingfillmanager.onfillupdatetimertick(object sender, eventargs eventargs) @ system.windows.forms.timer.ontick(eventargs e) @ system.windows.forms.timer.timernativewindow.wndproc(message& m) @ system.windows.forms.nativewindow.callback(intptr hwnd, int32 msg, intptr wparam, intptr lparam)
user id: f1b43d3f-ed65-4886-993e-0d6507a0de3f
supports premium content: true
telemetry enabled: true
dpi scale: 100%
formulas:
section section1;
shared #"datarecords campaign_000008" = let Źródło = postgresql.database("10.100.120.18", "contactdirect"), datarecords_campaign_000008 = Źródło{[schema="datarecords",item="campaign_000008"]}[data] in datarecords_campaign_000008;
shared #"datarecords campaign_000008_changelog" = let Źródło = postgresql.database("10.100.120.18", "contactdirect"), datarecords_campaign_000008_changelog = Źródło{[schema="datarecords",item="campaign_000008_changelog"]}[data] in datarecords_campaign_000008_changelog;
the answer is: bug in npgsql 3.2.5 - after installing 3.1.9 - works gr8 ;)
Comments
Post a Comment