Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

System.AccessViolationException in Powerbuilder.NET

Hi ,

I have created a wcf service with powerbuilder .NET 12.5 build 5609.

I have used inside my function a datastore with a very simple datawindow were I'm looping to get the data.

The thing is that the first time I call the method from my application I get in my IIS the below

In my svc I'm connecting to an SQLServer 2012 to get data. I use the OLE DB in the dbms type and the below in my dbparm

"PROVIDER='SQLOLEDB',DATASOURCE='MYMACHINE',PROVIDERSTRING='database=DB_3'"

I have also changed the providers to SQLNCI11 use the native client but nothing.

So I get the below and this is happening when I use a Datastore with a Datawindow.

My Web server is windows 2008 R2 standard 64bit

Application: w3wp.exe

Framework Version: v4.0.30319

Description: The process was terminated due to an unhandled exception.

Exception Info: System.AccessViolationException

Stack:

   at <Module>.l(si*)

   at <Module>.e(d*)

   at Sybase.PowerBuilder.DataSource.Db.CommandBlock.Cancel()

   at Sybase.PowerBuilder.DataSource.DSCommand.Cancel()

   at Sybase.PowerBuilder.DataSource.DSCommand.Dispose()

   at Sybase.PowerBuilder.DataSource.DSCommand.a(System.Object, System.EventArgs)

   at System.EventHandler.Invoke(System.Object, System.EventArgs)

   at Sybase.PowerBuilder.DataSource.DSConnection.Close()

   at Sybase.PowerBuilder.DSI.PBSQL.DSISQLFunc.Stop(Sybase.PowerBuilder.PBSessionBase, Sybase.PowerBuilder.PBTransaction)

   at c__n_wcfjsonhotel.db_disconnect_1_1528663888[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]](System.__Canon ByRef)

   at c__n_wcfjsonhotel.f_get_regguest(Sybase.PowerBuilder.PBString, Sybase.PowerBuilder.PBString, Sybase.PowerBuilder.PBString, Sybase.PowerBuilder.PBLong, Sybase.PowerBuilder.PBLong, Sybase.PowerBuilder.PBString)

   at Sybase.PowerBuilder.WCFNVO.n_wcfjsonhotel.f_get_regguest(System.String, System.String, System.String, Int32, Int32, System.String)

   at DynamicClass.SyncInvokef_get_regguest(System.Object, System.Object[], System.Object[])

   at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(System.Object, System.Object[], System.Object[] ByRef)

   at System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(System.ServiceModel.Dispatcher.MessageRpc ByRef)

   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(System.ServiceModel.Dispatcher.MessageRpc ByRef)

   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage41(System.ServiceModel.Dispatcher.MessageRpc ByRef)

   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage4(System.ServiceModel.Dispatcher.MessageRpc ByRef)

   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage31(System.ServiceModel.Dispatcher.MessageRpc ByRef)

   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage3(System.ServiceModel.Dispatcher.MessageRpc ByRef)

   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage2(System.ServiceModel.Dispatcher.MessageRpc ByRef)

   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage11(System.ServiceModel.Dispatcher.MessageRpc ByRef)

   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage1(System.ServiceModel.Dispatcher.MessageRpc ByRef)

   at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean)

   at System.ServiceModel.Dispatcher.ChannelHandler.DispatchAndReleasePump(System.ServiceModel.Channels.RequestContext, Boolean, System.ServiceModel.OperationContext)

   at System.ServiceModel.Dispatcher.ChannelHandler.HandleRequest(System.ServiceModel.Channels.RequestContext, System.ServiceModel.OperationContext)

   at System.ServiceModel.Dispatcher.ChannelHandler.AsyncMessagePump(System.IAsyncResult)

   at System.ServiceModel.Dispatcher.ChannelHandler.OnAsyncReceiveComplete(System.IAsyncResult)

   at System.Runtime.Fx+AsyncThunk.UnhandledExceptionFrame(System.IAsyncResult)

   at System.Runtime.AsyncResult.Complete(Boolean)

   at System.Runtime.InputQueue`1+AsyncQueueReader[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].Set(Item<System.__Canon>)

   at System.Runtime.InputQueue`1[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].EnqueueAndDispatch(Item<System.__Canon>, Boolean)

   at System.Runtime.InputQueue`1[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].EnqueueAndDispatch(System.__Canon, System.Action, Boolean)

   at System.ServiceModel.Channels.SingletonChannelAcceptor`3[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].Enqueue(System.__Canon, System.Action, Boolean)

   at System.ServiceModel.Channels.HttpPipeline+EnqueueMessageAsyncResult.CompleteParseAndEnqueue(System.IAsyncResult)

   at System.ServiceModel.Channels.HttpPipeline+EnqueueMessageAsyncResult.HandleParseIncomingMessage(System.IAsyncResult)

   at System.Runtime.AsyncResult.AsyncCompletionWrapperCallback(System.IAsyncResult)

   at System.Runtime.Fx+AsyncThunk.UnhandledExceptionFrame(System.IAsyncResult)

   at System.Runtime.AsyncResult.Complete(Boolean)

   at System.Runtime.AsyncResult.Complete(Boolean, System.Exception)

   at System.ServiceModel.Channels.HttpInput+ParseMessageAsyncResult.OnRead(System.IAsyncResult)

   at System.Runtime.Fx+AsyncThunk.UnhandledExceptionFrame(System.IAsyncResult)

   at System.IO.Stream+ReadWriteTask.InvokeAsyncCallback(System.Object)

   at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)

   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)

   at System.IO.Stream+ReadWriteTask.System.Threading.Tasks.ITaskCompletionAction.Invoke(System.Threading.Tasks.Task)

   at System.Threading.Tasks.Task.FinishContinuations()

   at System.Threading.Tasks.Task.FinishStageThree()

   at System.Threading.Tasks.Task.FinishStageTwo()

   at System.Threading.Tasks.Task.Finish(Boolean)

   at System.Threading.Tasks.Task.ExecuteWithThreadLocal(System.Threading.Tasks.Task ByRef)

   at System.Threading.Tasks.Task.ExecuteEntry(Boolean)

   at System.Threading.Tasks.Task.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()

   at System.Threading.ThreadPoolWorkQueue.Dispatch()

   at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()

Also I get the below

Faulting application name: w3wp.exe, version: 7.5.7601.17514, time stamp: 0x4ce7a5f8

Faulting module name: pbOLE125.dll, version: 12.5.2.5609, time stamp: 0x52c50d6c

Exception code: 0xc0000005

Fault offset: 0x0001c62b

Faulting process id: 0x11a0

Faulting application start time: 0x01d02f6f57aee718

Faulting application path: C:\Windows\SysWOW64\inetsrv\w3wp.exe

Faulting module path: C:\Program Files (x86)\Sybase\Shared\PowerBuilder\pbOLE125.dll

Report Id: 989a34a0-9b62-11e4-b4f5-2c413807d37d

Can anyone assist me on this ?

Does anyone has an idea ?

Appreciate any help you could give me.

thank you

Former Member
Not what you were looking for? View more on this topic or Ask a question