Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Conversion failed when converting nvarchar value to 'Mar' to data type int

Hello all,

I am trying to execute a scrip and when I reload it it gives the following error:

ErrorSource: Microsoft OLE DB Provider for SQL Server, ErrorMsg: Conversion failed when converting the nvarchar value 'Mar' to data type int.

The sql runs fine in the database.

Below is the sql select statement:

SQL SELECT
    ac.Month,
    ac.CalendarYear,
    c.FiscalYear as FiscalYear,
c.FiscalPeriod as FiscalPeriod,
c.FiscalQtr as FiscalQtr,
    ac.Month,
    ac.Entity,
    ac.PTInitialEval,
    d.System as System,
d.Division as Division,

d.Location as Location

from dbo.XYZ_ ac
join dbo.Calendar c
on c.Month = ac.Month
  and c.Year = ac.CalendarYear
join dbo._DivisionCrossWalk d
on d.Entity = ac.Entity
order by FiscalYear
  ,FiscalPeriod

I am very new to qlikview and not sure where the problem is in the script.

Thanks,

Swati

2 Replies
el_aprendiz111
Specialist

Hi,

1 example

Follow the assistant

conex.gif

vishsaggi
Champion III

What are the field values for the Field Month in these two tables

dbo.XYZ_ ac

AND

dbo.Calendar c


on c.Month = ac.Month  --> There might be a mismatch happening here? Can you check ?