Quantcast
Channel: SCN: Message List - SAP Adaptive Server Enterprise Developer Center
Viewing all 1240 articles
Browse latest View live

How to clean missing statistics information from system tables.

$
0
0

Greetings,

     After enabling 'capture missing statistics' our master database filled up in the past. We would like to enable this option periodically and then collect that information, analyse it to create or update existing indexes and also clean the missing stats from system tables before we enable the option to start analysing again.


     Is there any way to clean old missing statistics information from system tables in ASE 16?

 

With regards,

Sid.


Re: System.AccessViolationException in 64 bit ASE client on server

$
0
0

Hi Ram,


If you do process explorer and watch w3wp.exe and see where it is loading the files. I have a feeling your application is pulling sybdrvado20.dll from some other location or a different version then the temp directory.

 

So basically when you use the newer driver everything is included in the one .dll. It expands in a temp directory. Make sure the user has permissions on this directory also. I remember seeing an issue with SSIS with this.

 

If the above doesn't help add protocolcapture=C:\somepath\mytrace to the connection string.
You can change this to a text file  by using ribo and read through this it might tell you what is the last call being made so maybe this might point to issue.
ref: Setting up oledb with Protocol Capture - SAP Connectivity - SCN Wiki
ref: TDS Tracing tool Ribo on Windows - ERP Financials - SCN Wiki

 

Thanks,
Dawn Kim

Re: windows 2012 64 bit Sybase.AdoNet4.AseClient version?

$
0
0

Hi Ram,

 

We have been certified with Sybase.AdoNet4.AseClient with Windows 2012 since SDK 15.7 ESD#6 and higher and SDK 16.0 SP00 PL00 and higher.

 

We just recently got certified with Studio 2012 with SDK 15.7 SP133 and higher or SDK 16.0 SP01 PL01. You could still use it but you had to manually add registry entries.

 

As far as I know we aren't certified with Studio 2013. But you can still work with it by manually adding registry entries.

 

Thanks,
Dawn Kim

 

ps: if you want to see the versions of the drivers installed in the SDK for Windows you can look at this spreadsheet: Software Developer Kit for ASE driver versions for Windows - Wiki - SCN Wiki

Re: How to clean missing statistics information from system tables.

$
0
0

Missing statistics are stored in the "sysstatistics" table for each database.  Look for "formatid" of 110.

 

For example:

select  user_name(so.uid),so.name,ss.colidarray

 

                from    sysobjects so INNER JOIN  sysstatistics ss

 

ON  so.id = ss.id

 

                 where   so.type                 = "U"

 

    and so.sysstat2 & 1024 != 1024

 

     and         so.sysstat2 & 2048      != 2048      /* regular tables */

 

     and     ss.formatid             = 110           /* missing statistics formatid */

 

 

 

One could write a "delete" statement based on the logic above and  create a stored proc (while "allow system table updates" is set on) that could delete these rows from sysstatistics.  The proc could accept a table name (and even a column name), or such that would control doing this for certain tables/columns, or all tables/columns etc.

Query allocation in case multiple tempdb

$
0
0

I have one SYBASE ASE 16.0 Database running having 5 tempdb and each of them of 500MB.

 

Now suppose one query is trying to allocate 600 MB tempdb to execute it, in this scenario what will be the result:

     Will the query be aborted as each tempdb is of 500MB and query is needed 600MB ?

      Or will it take 2 tempdb to execute it successfully?

 

Please help me if you know the answer.

Re: Query allocation in case multiple tempdb

$
0
0


Each connection (spid) can only use one tempdb.  So the query would abort.

Re: Query allocation in case multiple tempdb

$
0
0

Thanks Bret.

 

Also, can you please let me know the advantage of using multiple tempdb (no binding) over one more sized tempdb?

 

I have tried to find the answer hard but not convinced of any answer.

 

Thanks again in advance.

Re: Query allocation in case multiple tempdb

$
0
0

Multiple tempdbs are used to reduce contention on tempdb.


What is the cost for ASM(advance security) , IMDB (In Memory database)

$
0
0

Are they free and you just need a license, or you have to pay big bucks ?

 

Thanks

Re: System.AccessViolationException in 64 bit ASE client on server

$
0
0

We don't have any other sybase file except   Sybase.AdoNet4.AseClient.dll  4.157.1300.0 in windows 2012 server. Please advise

 

Analysis symbol:

Rechecking for solution: 0

Report Id: cb7c6f90-419d-11e5-9417-005056935d0b

Report Status: 4

Hashed bucket: "

Error 8/13/2015 5:29:29 AM Application Error 1000 (100) "Faulting application name: w3wp.exe, version: 8.0.9200.16384, time stamp: 0x50108835

Faulting module name: sybdrvado20.dll, version: 2.157.1300.0, time stamp: 0x53c85084

Exception code: 0x40000015

Fault offset: 0x0000000000007c32

Faulting process id: 0x1c68

Faulting application start time: 0x01d0d59b5268bfa1

Faulting application path: c:\windows\system32\inetsrv\w3wp.exe

Faulting module path: C:\Windows\TEMP\Sybase.AdoNet4.AseClient.64bits.4.157.1300.0\sybdrvado20.dll

Report Id: cb7c6f90-419d-11e5-9417-005056935d0b

Faulting package full name:

Faulting package-relative application ID: "

SAP Sybase DBACOCKPIT Error

$
0
0

Hi Experts,

 

I Had made a System copy and done all   post installation  process, but when i try t-code dbacockpit  i get web page one in it , can any one help me how to configure the back-end to get DBACOCKPIT work, our system is SAP ECC 6 EHP 7 Sysbase DB

 

 

thank you

 

SROY

Re: SAP Sybase DBACOCKPIT Error

Re: System.AccessViolationException in 64 bit ASE client on server

$
0
0

Hi Paul,

 

1) In my case we are using 4.0 .NET with the ASE 4.0 Provider(Sybase.AdoNet4.AseClient.dll  product version 4.157.1300.0) this is the only sybase DLL in the bin on the server.

(No sybase component installed on server)

 

2) I am more into .net Role. What is TDS?.Should it be installed on windows 2012 server box?  or on Sybase server host box.

 

 

 

3)Does this happen often (how many times per X?)

Error is happening 5-6 times in day (based on traffic it  may be more ). 1 or 2 App pool  crash in  a day.


4)Did it start happening with an upgrade of something (what?) or is this a new application.

We migrated from  Windows 2003 (32 bit ) to  Windows  2012 64 bit. and it started happening (we dont have issues when we are on 2003 box (32 bit))

 

5)How do you mitigate it now?

We are restarting appool whenever it is happening.


6)What sort of load is on this app at the time - about how many concurrent connections?

500 approx

 

7)It could be this is a timing issue but seems some memory is corrupted somewhere, somehow.

 

 

Is it possible to try SP133 build?

Re: System.AccessViolationException in 64 bit ASE client on server

$
0
0

Is it possible to try SP133 build?


Where should i download this from please provide me instructions.


Here is the more error info

 

 

DetailID = 5

  Count:    1

  Type:     System.TypeInitializationException

  Message:  The type initializer for 'Sybase.Data.AseClient1.AseConnection' threw an exception.

  Type:     System.UnauthorizedAccessException

  Message:  Access to the path 'C:\Windows\TEMP\Sybase.AdoNet4.AseClient.64bits.4.157.1300.0' is denied.

  Stack:   

  [GCFrame]

  [GCFrame]

  [PrestubMethodFrame]

  Sybase.Data.AseClient.AseConnection..ctor(System.String)

  dbtemp.DBServer.GetNewConnection()

  dbtemp.DBServer.CreateTransaction()

  ERMS.LanguageLoader..ctor()

  ASP.global_asax.Session_Start(System.Object, System.EventArgs)

  System.Web.SessionState.SessionStateModule.CompleteAcquireState()

  System.Web.SessionState.SessionStateModule.BeginAcquireState(System.Object, System.EventArgs, System.AsyncCallback, System.Object)

  System.Web.HttpApplication+AsyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()

  System.Web.HttpApplication.ExecuteStep(IExecutionStep, Boolean ByRef)

  System.Web.HttpApplication+PipelineStepManager.ResumeSteps(System.Exception)

  System.Web.HttpApplication.BeginProcessRequestNotification(System.Web.HttpContext, System.AsyncCallback)

  System.Web.HttpRuntime.ProcessRequestNotificationPrivate(System.Web.Hosting.IIS7WorkerRequest, System.Web.HttpContext)

  System.Web.Hosting.PipelineRuntime.ProcessRequestNotificationHelper(IntPtr, IntPtr, IntPtr, Int32)

  System.Web.Hosting.PipelineRuntime.ProcessRequestNotification(IntPtr, IntPtr, IntPtr, Int32)

  DomainNeutralILStubClass.IL_STUB_ReversePInvoke(Int64, Int64, Int64, Int32)

  [InlinedCallFrame]

  [InlinedCallFrame]

  DomainNeutralILStubClass.IL_STUB_PInvoke(IntPtr, System.Web.RequestNotificationStatus ByRef)

  System.Web.Hosting.PipelineRuntime.ProcessRequestNotificationHelper(IntPtr, IntPtr, IntPtr, Int32)

  System.Web.Hosting.PipelineRuntime.ProcessRequestNotification(IntPtr, IntPtr, IntPtr, Int32)

  DomainNeutralILStubClass.IL_STUB_ReversePInvoke(Int64, Int64, Int64, Int32)

  [ContextTransitionFrame]

 

 

 

 

DetailID = 6

  Count:    1

  Type:     System.TypeInitializationException

  Message:  The type initializer for 'Sybase.Data.AseClient1.AseConnection' threw an exception.

  Type:     System.UnauthorizedAccessException

  Message:  Access to the path 'C:\Windows\TEMP\Sybase.AdoNet4.AseClient.64bits.4.157.1300.0' is denied.

  Stack:   

  [GCFrame]

  [PrestubMethodFrame]

  Sybase.Data.AseClient.AseConnection..ctor(System.String)

  dbtemp.DBServer.GetNewConnection()

  dbtemp.DBServer.CreateTransaction()

  ERMS.SystemMonitor.checkLock()

  ERMS.SystemMonitor.monitorUILock()

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

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

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

  System.Threading.ThreadHelper.ThreadStart()

  [GCFrame]

  [DebuggerU2MCatchHandlerFrame]

  [ContextTransitionFrame]

  [DebuggerU2MCatchHandlerFrame]

 

 

 

 

DetailID = 7

  Count:    1

  Type:     dbtemp.DBException

  Message:  DBServer::GetConnection: Sybase.AdoNet4.AseClient: The type initializer for 'Sybase.Data.AseClient1.AseConnection' threw an exception.:    at Sybase.Data.AseClient1.AseConnection..ctor(AseConnection realConnection, String connectionString)

 

 

   at Sybase.Data.AseClient.AseConnection..ctor(String connectionString)

 

 

   at dbtemp.DBServer.GetNewConnection()

  Stack:   

  [HelperMethodFrame]

  dbtemp.DBServer.GetNewConnection()

  [GCFrame]

  [PrestubMethodFrame]

  Sybase.Data.AseClient.AseConnection..ctor(System.String)

  dbtemp.DBServer.GetNewConnection()

  dbtemp.DBServer.CreateTransaction()

  ERMS.SystemMonitor.checkLock()

  ERMS.SystemMonitor.monitorUILock()

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

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

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

  System.Threading.ThreadHelper.ThreadStart()

  [GCFrame]

  [DebuggerU2MCatchHandlerFrame]

  [ContextTransitionFrame]

  [DebuggerU2MCatchHandlerFrame]

 

 

 

 

DetailID = 8

  Count:    1

  Type:     dbtemp.DBException

  Message:  DBServer::GetConnection: Sybase.AdoNet4.AseClient: The type initializer for 'Sybase.Data.AseClient1.AseConnection' threw an exception.:    at Sybase.Data.AseClient1.AseConnection..ctor(AseConnection realConnection, String connectionString)

 

 

   at Sybase.Data.AseClient.AseConnection..ctor(String connectionString)

 

 

   at dbtemp.DBServer.GetNewConnection()

  Stack:   

  [HelperMethodFrame]

  dbtemp.DBServer.CreateTransaction()

  [HelperMethodFrame]

  dbtemp.DBServer.GetNewConnection()

  [GCFrame]

  [PrestubMethodFrame]

  Sybase.Data.AseClient.AseConnection..ctor(System.String)

  dbtemp.DBServer.GetNewConnection()

  dbtemp.DBServer.CreateTransaction()

  ERMS.SystemMonitor.checkLock()

  ERMS.SystemMonitor.monitorUILock()

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

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

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

  System.Threading.ThreadHelper.ThreadStart()

  [GCFrame]

  [DebuggerU2MCatchHandlerFrame]

  [ContextTransitionFrame]

  [DebuggerU2MCatchHandlerFrame]

 

 

 

 

DetailID = 9

  Count:    1

  Type:     dbtemp.DBException

  Message:  DBServer::GetConnection: Sybase.AdoNet4.AseClient: The type initializer for 'Sybase.Data.AseClient1.AseConnection' threw an exception.:    at Sybase.Data.AseClient1.AseConnection..ctor(AseConnection realConnection, String connectionString)

 

 

   at Sybase.Data.AseClient.AseConnection..ctor(String connectionString)

 

 

   at dbtemp.DBServer.GetNewConnection()

  Stack:   

  [HelperMethodFrame]

  ERMS.SystemMonitor.monitorUILock()

  [HelperMethodFrame]

  dbtemp.DBServer.CreateTransaction()

  [HelperMethodFrame]

  dbtemp.DBServer.GetNewConnection()

  [GCFrame]

  [PrestubMethodFrame]

  Sybase.Data.AseClient.AseConnection..ctor(System.String)

  dbtemp.DBServer.GetNewConnection()

  dbtemp.DBServer.CreateTransaction()

  ERMS.SystemMonitor.checkLock()

  ERMS.SystemMonitor.monitorUILock()

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

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

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

  System.Threading.ThreadHelper.ThreadStart()

  [GCFrame]

  [DebuggerU2MCatchHandlerFrame]

  [ContextTransitionFrame]

  [DebuggerU2MCatchHandlerFrame]

Re: System.AccessViolationException in 64 bit ASE client on server

$
0
0

Hi Ram,

 

TDS is Tabular Data Stream - it's the communication protocol between client and server and doesn't require installation, it is built into the product - it is how communication occurs between the .NET clients and the ASE.

 

Seems to be an issue related to upgrading application to a more robust OS/machine.  During the AseCommand.Dispose() call the Provider checks to make sure all network and intermediary buffers are cleaned out before destroying the AseCommand object.

 

I just got your other reply and need to look into that.

 

To get SP133 you can go to the SAP download page:

 

 

1. Go to  https://support.sap.com/software.html

 

2. Select the Support Packages and Patches item

 

3. Select A-Z

 

4. Select "S"

 

5. Select SDK for SAP ASE and then select the version and platform (15.7 or
16.0)

 

Cheers,

-Paul


Re: System.AccessViolationException in 64 bit ASE client on server

$
0
0

Hi Ram,


This looks like a different issue.  Can you please let us know how, exactly, do you deploy the provider?

 

When AseConnection is invoked, the Provider contains the un-managed DLLs, embedded in it's own DLL. These are copied to location, like in this case maybe C:\windows\temp\ because it is IIS doing this.

 

It is unusual to be denied access to the Windows\TEMP directory and this is happening on new connections - this wasn't happening before in the access violation - in that situation you are connecting , etc. So what changed in this case?  Something did since the Provider doesn't spontaneously decide itself don't have rights to a specific directory - this is something happening externally.

This directory:

'C:\Windows\TEMP\Sybase.AdoNet4.AseClient.64bits.4.157.1300.0

is where the Provider copies the proper version of sybdrvado20.dll - this is the un-managed layer handling the TDS - the communication to the ASE.  When the constructor:

 

Sybase.Data.AseClient.AseConnection..ctor(System.String)

 

call is invoked, the Provider first checks for existence of that directory, then if not, creates directory and copies the platform specific version of the sybdrvado20.dll there.  If it exists, it loads that DLL. In your case it is clearly being denied access to the directory and this isn't making sense.

 

The only thing I can think of now is the directory was initially created by one app pool, with a specific ID and now another app pool is trying to access and has no rights to this directory.  Can you check this?  See if app pools are using different windows ids?

 

Also, please find the specific rights for the 'C:\Windows\TEMP\Sybase.AdoNet4.AseClient.64bits.4.157.1300.0 directory - you can look at the directory properties, and check Security I think - this should list the users and their access rights. The app pool users require full access to the directory.

 

Cheers,

-Paul

Re: System.AccessViolationException in 64 bit ASE client on server

$
0
0

Hi Ram,

 

Okay to capture the tds layer, put PROTOCOLCAPTURE=c:\somelocation\mytrace in the connection string of the application.
Or you can do a wire shark maybe this will catch the thread.

 

We had an old issue but this was fixed in SDK 15.7 SP120 and higher and is included with the SDK 15.7 SP130 and SP133.
The workaround was to make sure  group IIS_IUSERS needs full permissions on the C:\Windows\Temp folder. Can you double check and make sure this happening?

 

So like Paul said above, it is something about he initial connection, so make sure the users that are part of the app pool have permissions to that directory also.

 

Thanks,
Dawn Kim

 


Re: System.AccessViolationException in 64 bit ASE client on server

$
0
0

Hi Paul,

 

 

This is asking us used id  password . I dont have to enter any when i downloaded SDK. Please help.

 

Regards,

Ram

Re: System.AccessViolationException in 64 bit ASE client on server

$
0
0

Hi Paul,

 

 

 

 

Can you please let us know how, exactly, do you deploy the provider?

 

 

 

Sybase.AdoNet4.AseClient.dll  is referenced in Visual studio Bin folder of Asp.net website  and published the web project.

When deployed, Bin folder will have website dll and Sybase.AdoNet4.AseClient.dll  along with web project folders.

 

Do you see any problem above?

 

 

 

 

 

I will check on the folder permissions and re post the info.

 

Regards,

Ram

Re: System.AccessViolationException in 64 bit ASE client on server

$
0
0

Hi Ram,

 

See if you can get the free development SDK.

There is a trial/free version of the SDK up on the site currently.

 

Go here: http://scn.sap.com/community/downloads

 

There is an article titled "The SCN Download Center is Now on the SAP Store: What's New?"

 

In this article there is a link to the SAP store click it

 

Than do a search for "SAP SDK for Adaptive Server Enterprise"

Click the free trial and it will ask for your information and send you an email.

 

From the link you get you should see a list of the current SDKs.

Viewing all 1240 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>