Information: Forum is in read-only mode
For details and other support options see https://www.adiscon.com/news/support-forum-set-to-read-only-mode/

editing view definition: Specified cast is not valid

Support, Questions and Discussions on MonitorWare Console

Moderator: alorbach

Google Ads


editing view definition: Specified cast is not valid

Postby tosh » Mon Apr 28, 2003 1:32 pm

Hi

New problem for you

In the events view, editing a View Definition, gives me the following error:

source: MWConsole
message: Specified cast is not valid
details: System.InvalidCastException: Specified cast is not valid.
at Adiscon.MonitorWare.Console.CommonFilterForm.fillDevices()

It then lets me into the view definition dialog box, and continues working ok (I can change the view and my settings are saved).


So this isn't a showstopper, as everything seems to be working!

I really like the app, and am going headlong into customisation now - is the customisation stored in the database (available at other workstations)?

Also - I can't get anything to work in Devices / Discovery - is this off limits for the time being?
tosh
Frequent Poster
 
Posts: 83
Joined: Fri Feb 28, 2003 3:14 pm
Location: London, UK

Postby alorbach » Mon Apr 28, 2003 1:45 pm

Hi Tosh,

the devices/discovery part should work, however there might be missing another field again (Which also would explain the exception you are getting in the Edit View formular).

Could you tell me again the exact version you are currently using? I want to send you a debug file. With this file, we can find out at which position within the program the error is exactly happening.
alorbach
Site Admin
 
Posts: 1627
Joined: Thu Feb 13, 2003 11:55 am

Postby tosh » Mon Apr 28, 2003 2:06 pm

Hi Andre

The version of the exe is 1.0.1374.29430

The actual error message when pressing the Discover button is:

Source:
sqlsrv32.dll

Message:
ERROR [42000] [Microsoft][ODBC SQL Server Driver][SQL Server]Cannot resolve collation conflict for equal to operation.

Details:
Microsoft.Data.Odbc.OdbcException: ERROR [42000] [Microsoft][ODBC SQL Server Driver][SQL Server]Cannot resolve collation conflict for equal to operation.
at Microsoft.Data.Odbc.OdbcConnection.HandleError(IntPtr hHandle, SQL_HANDLE hType, RETCODE retcode)
at Microsoft.Data.Odbc.OdbcCommand.ExecuteReaderObject(CommandBehavior behavior, String method)
at Microsoft.Data.Odbc.OdbcCommand.ExecuteReader(CommandBehavior behavior)
at Microsoft.Data.Odbc.OdbcCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(Object data, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataTable dataTable, IDbCommand command, CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataTable dataTable)
at Adiscon.MonitorWare.Console.DiscoverDevicesForm.cmdRefresh_Click(Object sender, EventArgs e)

TIA
tosh
Frequent Poster
 
Posts: 83
Joined: Fri Feb 28, 2003 3:14 pm
Location: London, UK

Postby alorbach » Mon Apr 28, 2003 2:19 pm

Thanks,

I send a debug file to your email address. Please copy it into the MWConsole directory, and restart MWConsole. After that you will get a more detailed error message. Please send this error message by email to us.

thanks... ;)
alorbach
Site Admin
 
Posts: 1627
Joined: Thu Feb 13, 2003 11:55 am

Postby tosh » Mon Apr 28, 2003 2:34 pm

got it fine, thanks - here you go - "Error when pressing Discover in Devices"

source:
SQLSRV32.DLL

message:
ERROR [42000] [Microsoft][ODBC SQL Server Driver][SQL Server]Cannot resolve collation conflict for equal to operation.

details:
Microsoft.Data.Odbc.OdbcException: ERROR [42000] [Microsoft][ODBC SQL Server Driver][SQL Server]Cannot resolve collation conflict for equal to operation.
at Microsoft.Data.Odbc.OdbcConnection.HandleError(IntPtr hHandle, SQL_HANDLE hType, RETCODE retcode)
at Microsoft.Data.Odbc.OdbcCommand.ExecuteReaderObject(CommandBehavior behavior, String method)
at Microsoft.Data.Odbc.OdbcCommand.ExecuteReader(CommandBehavior behavior)
at Microsoft.Data.Odbc.OdbcCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(Object data, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataTable dataTable, IDbCommand command, CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataTable dataTable)
at Adiscon.MonitorWare.Console.DiscoverDevicesForm.cmdRefresh_Click(Object sender, EventArgs e) in D:\Produkte\Monitorware\MWConsole\DiscoverDevicesForm.cs:line 507
Last edited by tosh on Mon Apr 28, 2003 2:36 pm, edited 1 time in total.
tosh
Frequent Poster
 
Posts: 83
Joined: Fri Feb 28, 2003 3:14 pm
Location: London, UK

Postby tosh » Mon Apr 28, 2003 2:36 pm

and here is the error for the "Specified cast is not valid" issue

source:
MWConsole

message:
Specified cast is not valid.

details:
System.InvalidCastException: Specified cast is not valid.
at Adiscon.MonitorWare.Console.CommonFilterForm.fillDevices() in D:\Produkte\Monitorware\MWConsole\CommonFilterForm.cs:line 925
tosh
Frequent Poster
 
Posts: 83
Joined: Fri Feb 28, 2003 3:14 pm
Location: London, UK

Postby alorbach » Mon Apr 28, 2003 2:48 pm

I think I got the error, could you please check how your "FromHost" field in "SystemEvents" table is defined?

It should be "[FromHost] [nvarchar] (60) NULL".

Also a definition print of your SystemEvents table would be helpfull. Maybe I can find other issues.
alorbach
Site Admin
 
Posts: 1627
Joined: Thu Feb 13, 2003 11:55 am

Postby tosh » Mon Apr 28, 2003 3:10 pm

Sorry, but FromHost is in the systemevents table as described

Here is the current definition of SystemEvents - there are a few extra fields that I've added, so don't worry about those:

Code: Select all
1   ID         int      4   0
0   ReceivedAt      datetime   8   1
0   DeviceReportedTime   datetime   8   1
0   Facility      smallint   2   1
0   Priority      smallint   2   1
0   FromHost      nvarchar   60   1
0   Message         text      16   1
0   NTSeverity      int      4   1
0   Importance      int      4   1
0   EventSource      nvarchar   60   1
0   EventUser      nvarchar   60   1
0   EventCategory      int      4   1
0   EventID         int      4   1
0   EventBinaryData      text      16   1
0   MaxAvailable      int      4   1
0   CurrUsage      int      4   1
0   MinUsage      int      4   1
0   MaxUsage      int      4   1
0   InfoUnitID      int      4   1
0   SysLogTag      varchar      60   1
0   EventLogType      varchar      60   1
0   GenericFileName      varchar      60   1
0   CommHDID      varchar      50   1
0   Checked         bit      1   0
0   DateChecked      datetime   8   1
0   Checkedby      varchar      50   1
0   CustomerID      int      4   1
0   SystemID      int      4   1
tosh
Frequent Poster
 
Posts: 83
Joined: Fri Feb 28, 2003 3:14 pm
Location: London, UK

Postby tosh » Mon Apr 28, 2003 3:12 pm

another small thing

I don't get emails when this topic (or any subscribed topic) is updated - is the option available on the board? My email address is in my profile....
tosh
Frequent Poster
 
Posts: 83
Joined: Fri Feb 28, 2003 3:14 pm
Location: London, UK

Postby tosh » Mon Apr 28, 2003 3:16 pm

here's another dump:

Code: Select all
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[SystemEvents]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[SystemEvents]
GO

CREATE TABLE [dbo].[SystemEvents] (
   [ID] [int] IDENTITY (1, 1) NOT NULL ,
   [ReceivedAt] [datetime] NULL ,
   [DeviceReportedTime] [datetime] NULL ,
   [Facility] [smallint] NULL ,
   [Priority] [smallint] NULL ,
   [FromHost] [nvarchar] (60) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
   [Message] [text] COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
   [NTSeverity] [int] NULL ,
   [Importance] [int] NULL ,
   [EventSource] [nvarchar] (60) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
   [EventUser] [nvarchar] (60) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
   [EventCategory] [int] NULL ,
   [EventID] [int] NULL ,
   [EventBinaryData] [text] COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
   [MaxAvailable] [int] NULL ,
   [CurrUsage] [int] NULL ,
   [MinUsage] [int] NULL ,
   [MaxUsage] [int] NULL ,
   [InfoUnitID] [int] NULL ,
   [SysLogTag] [varchar] (60) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
   [EventLogType] [varchar] (60) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
   [GenericFileName] [varchar] (60) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
   [CommHDID] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
   [Checked] [bit] NOT NULL ,
   [DateChecked] [datetime] NULL ,
   [Checkedby] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
   [CustomerID] [int] NULL ,
   [SystemID] [int] NULL
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO



(thought I was going to get away from learning SQL....) :)
tosh
Frequent Poster
 
Posts: 83
Joined: Fri Feb 28, 2003 3:14 pm
Location: London, UK

Postby alorbach » Mon Apr 28, 2003 3:22 pm

Strange, there are four fields which are not used by MWConsole:

CommHDID
Checked
DateChecked
Checkedby

I guess you added this fields manually?
And there is a field CustomerID, it may comes from the database scripts, but is not used anymore.

I will look into this error again now, maybe I missed something.
alorbach
Site Admin
 
Posts: 1627
Joined: Thu Feb 13, 2003 11:55 am

Postby alorbach » Mon Apr 28, 2003 3:32 pm

tosh wrote:another small thing

I don't get emails when this topic (or any subscribed topic) is updated - is the option available on the board? My email address is in my profile....


In your profile you can enable "Always notify me of replies:" option.
alorbach
Site Admin
 
Posts: 1627
Joined: Thu Feb 13, 2003 11:55 am

Postby tosh » Mon Apr 28, 2003 3:33 pm

yes, those four are mine - I'll remove customerID from the database

thanks
tosh
Frequent Poster
 
Posts: 83
Joined: Fri Feb 28, 2003 3:14 pm
Location: London, UK

Postby tosh » Mon Apr 28, 2003 3:35 pm

alorbach wrote:
tosh wrote:another small thing

I don't get emails when this topic (or any subscribed topic) is updated - is the option available on the board? My email address is in my profile....


In your profile you can enable "Always notify me of replies:" option.


these are all turned on - I think this bbs hates me - won't send me an email... :?
tosh
Frequent Poster
 
Posts: 83
Joined: Fri Feb 28, 2003 3:14 pm
Location: London, UK

Postby alorbach » Mon Apr 28, 2003 3:41 pm

:| I'll check that...
alorbach
Site Admin
 
Posts: 1627
Joined: Thu Feb 13, 2003 11:55 am

Google Ads



Return to MonitorWare Console

Who is online

Users browsing this forum: No registered users and 0 guests

cron