Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Not applicable

Error while creating a calendar table

Dear Experts,

I am creating a Fiscal Calendar table for YTD calculation. Here is the script for the calendar creation:

Set vFM = 10 ;        // First month of fiscal year

Calendar:

Load

  Dual(fYear-1 &'/'& fYear, fYear)  as FYear,          // Dual fiscal year

    Dual(Month, fMonth)                as FMonth,      // Dual fiscal month

          *;

Load

  Year + If(Month>=$(vFM), 1, 0) as fYear,          // Numeric fiscal year

    Mod(Month-$(vFM), 12)+1        as fMonth,          // Numeric fiscal month

          *;

LOAD

  DATE(date_invoice) as date_invoice,

    year(date_invoice) as Year,

    Month(date_invoice) as Month,

    Monthname(date_invoice) as MonthYear

Resident account_invoice;

Everytime i try to load, it throws an

The following error occurred:

Table not found

The error occurred here:

LOAD DATE(date_invoice) as date_invoice, year(date_invoice) as Year, Month(date_invoice) as Month, Monthname(date_invoice) as MonthYear Resident account_invoice

Data has not been loaded. Please correct the error and try loading again.

Could somebody please point out what could be the potential problem?

Thanks

Swetha

1 Solution

Accepted Solutions
MVP
MVP

Re: Error while creating a calendar table

Hi,

I think account_invoice table is not there in your datamodel, replace it with corresponding table name.

If already there then try to move Calendar script to the end.

Regards,

Jagan.

4 Replies
MVP
MVP

Re: Error while creating a calendar table

Have you made sure that you have this table -> account_invoice. You need to make sure that the upper and lower case and spellings are correct.

MVP
MVP

Re: Error while creating a calendar table

Hi,

I think account_invoice table is not there in your datamodel, replace it with corresponding table name.

If already there then try to move Calendar script to the end.

Regards,

Jagan.

Re: Error while creating a calendar table

Please check the relevant table name from which you are getting Date_invoice and write the name of that table in resident load

Not applicable

Re: Error while creating a calendar table

Thanks everyone,

I moved the calendar script to the end and it worked.

Thanks

Swetha