cancel
Showing results for 
Search instead for 
Did you mean: 

SQLCode - 1: Table '_^_^_22072007....._^_^_' not found

Former Member
0 Kudos

This error occurs when inserting rows into a table which has dependant materialized view in SQLA12 db (see attached image for full details).

Any ideas on why this is happening?

This happens on 1 or 2 databases, the rest (90+) is working great.

This is databases which started out as ASA5.5 db's once upon a time.

Otherwise, everything works as it should.

Accepted Solutions (1)

Accepted Solutions (1)

chris_keating
Advisor
Advisor
0 Kudos

This is likely related to Engineering Case#756681 which is fixed in 16.0.0 Build 1829 or later and 12.0.1 Build 4071 or later.

Former Member
0 Kudos

Thanks Chris!

We'll try the EBF over the weekend.

Hopefully it will work.

Regards,

Bjarne Anker

Former Member
0 Kudos

We applied EBF 4142 for SQL Anywhere 12 this weekend, and today the problem occured again.

So there have to be another reason for this error.

Any other good suggestions out there?

Regards,

Bjarne Anker

Maritech Systems AS

Norway

jeff_albion
Employee
Employee
0 Kudos

Hi Bjarne,

This error should be fixed for the conditions that we had prevoiusly seen it on (as you had described, inserting rows into a table with a dependency to a materialized view) in CR #756681, but it's possible that there is a slightly different way you're seeing it. Would it be possible to provide us with a sample of the operations you're trying against the table and the table/materialized view definition when you see this error on 12.0.1.4142?

Thanks,

Jeff Albion

SAP Active Global Support

Former Member
0 Kudos

Hi Jeff!

This error occurs when we are running simple INSERT or UPDATE statement against one of the tables with dependency to the materialized view in PowerBuilder embedded SQL statement.

There are also triggers on at least one of the tables, so perhaps the combination can be the issue here?

This is the definition for the line-view:

ALTER VIEW "MTS"."WV730PrognoseSalgsLinjer" as

    select

    w733prognosesalg.klientnr,

    w733prognosesalg.uttakstype,

    w733prognosesalg.uttaksnr,

    w733prognosesalg.vareanr,

    cast(0 as decimal(10,3)) as pris,

    0 as lagerkvantum,

    0 as lagerantall,

    sum(totkvant) as prognosekvantum,

    sum(antall) as prognoseantall,

    sm002vare.hkode,

    sm002vare.beskrivelse,

    w733prognosesalg.ValPris,

    null as TollPr

    from

    w729salgshode

    join w733prognosesalg on w733prognosesalg.klientnr=w729salgshode.klientnr and w733prognosesalg.uttakstype=w729salgshode.uttakstype and w733prognosesalg.uttaksnr=w729salgshode.uttaksnr

        join sm002vare on sm002vare.klientnr=w733prognosesalg.klientnr and sm002vare.vareanr=w733prognosesalg.vareanr

    where

    w729salgshode.status = 0 and

    w729salgshode.uttakstype = 'SA' and

    w729salgshode.salgstype = 6

    group by

    w733prognosesalg.klientnr,

    w733prognosesalg.uttakstype,

    sm002vare.beskrivelse,

    sm002vare.hkode,

    w733prognosesalg.vareanr,

    pris,

    w733prognosesalg.uttaksnr,

    w733prognosesalg.ValPris

   

    union

   

    select

    wmv730salgslinje.klientnr,

    wmv730salgslinje.uttakstype,

    wmv730salgslinje.uttaksnr,

    wmv730salgslinje.vareanr,

    wmv730salgslinje.pris,

    sum(totkvant) as lagerkvantum,

    sum(antall) as lagerantall,

    0 as prognosekvantum,

    0 as prognoseantall,

    sm002vare.hkode,

    sm002vare.beskrivelse,

    wmv730salgslinje.valpris as ValPris,

    wmv730salgslinje.tollpr as TollPr

    from

    w729salgshode

    join wmv730salgslinje on wmv730salgslinje.klientnr=w729salgshode.klientnr and wmv730salgslinje.uttakstype=w729salgshode.uttakstype and wmv730salgslinje.uttaksnr=w729salgshode.uttaksnr

    join sm002vare on sm002vare.klientnr=wmv730salgslinje.klientnr and sm002vare.vareanr=wmv730salgslinje.vareanr

    where

    w729salgshode.status = 0 and

    w729salgshode.uttakstype = 'SA' and

    w729salgshode.salgstype = 6

    group by

    wmv730salgslinje.klientnr,

    wmv730salgslinje.uttakstype,

    sm002vare.beskrivelse,

    sm002vare.hkode,

    wmv730salgslinje.vareanr,

    wmv730salgslinje.pris,

    wmv730salgslinje.uttaksnr,

    wmv730salgslinje.valpris,

    wmv730salgslinje.tollpr

   

    union

   

    select

    w770uttaksbestilling.klientnr,

        w770uttaksbestilling.uttakstype,

        w770uttaksbestilling.uttaksnr,

        w770uttaksbestilling.vareanr,

        cast(0 as decimal(10,3)) as pris,

        0 as lagerkvantum,

        0 as lagerantall,

        sum(kvantum) as prognosekvantum,

        sum(antall) as prognoseantall,

        sm002vare.hkode,

        sm002vare.beskrivelse,

        null as ValPris,

        null as TollPr

    from

        W729Salgshode

    join w770uttaksbestilling on w770uttaksbestilling.klientnr=w729salgshode.klientnr and w770uttaksbestilling.uttakstype=w729salgshode.uttakstype and w770uttaksbestilling.uttaksnr=w729salgshode.uttaksnr

        join sm002vare on sm002vare.klientnr=w770uttaksbestilling.klientnr and sm002vare.vareanr=w770uttaksbestilling.vareanr

    where

        w729salgshode.status = 0 and

        w729salgshode.uttakstype = 'SA' and

        w729salgshode.salgstype = 6 and

        not exists(select 1 from W733PrognoseSalg as x where x.KlientNr=w770uttaksbestilling.KlientNr and x.UttaksType=w770uttaksbestilling.UttaksType and x.UttaksNr=w770uttaksbestilling.UttaksNr)

    group by

    w770uttaksbestilling.klientnr,

    w770uttaksbestilling.uttakstype,

    sm002vare.beskrivelse,

    sm002vare.hkode,

    w770uttaksbestilling.vareanr,

    pris,

    w770uttaksbestilling.uttaksnr;

And this is the definition for the other view which is referred:

CREATE MATERIALIZED VIEW "MTS"."WMV730SalgsLinje"

    AS

    select

    w730salgslinje.klientnr,

    w730salgslinje.uttakstype,

    w730salgslinje.uttaksnr,

        w730salgslinje.w730lnr,

    w730salgslinje.vareanr,

    w730salgslinje.pris,

    w730salgslinje.totkvant,

    w730salgslinje.antall,

    0 as prognosekvantum,

    0 as prognoseantall,

    sm002vare.hkode,

    sm002vare.beskrivelse,

    w730salgslinje.valpris as ValPris,

    w730salgslinje.tollpr as TollPr

    from

    w729salgshode

    join w730salgslinje on w730salgslinje.klientnr=w729salgshode.klientnr and w730salgslinje.uttakstype=w729salgshode.uttakstype and w730salgslinje.uttaksnr=w729salgshode.uttaksnr

    join sm002vare on sm002vare.klientnr=w730salgslinje.klientnr and sm002vare.vareanr=w730salgslinje.vareanr

    where

    w729salgshode.status = 0 and

    w729salgshode.uttakstype = 'SA' and

    w729salgshode.salgstype = 6;

The weird thing is that all these views are in use for all of our installations, but fails only on 1 database. All other databases acts normal.

I think I can provide the database if that's needed.

Regards,

Bjarne Anker

Maritech Systems AS

Norway

jeff_albion
Employee
Employee
0 Kudos

Hi Bjarne,

This is quite a complicated definition that seems to involve many other corresponding tables. I think it might make more sense if you could upload a sample database file with the problem. If not, at least making the database schema available to us should help with the reproducible.

---

If you have a support plan with SAP, now would be an excellent time to open an incident and provide us the details for this problem over the support website so we can work with you directly to figure out what the best resolution will be. See: http://support.sap.com/

Otherwise, if you would like to just file a 'bug report' with us, I have created a shared space where you can upload files to on SAP Mobile Documents. Please e-mail ( firstname.lastname@sap.com ) or private message myself directly over SCN for the password to upload to the share area.

Thanks,

Jeff Albion

SAP Active Global Support


Former Member
0 Kudos

I've created an incident on support.sap.com just now (0001081327 2014).

The database has been uploaded to your FTP-site.

Regards.

Bjarne Anker

Maritech Systems AS

Norway

jeff_albion
Employee
Employee
0 Kudos

Thanks Bjarne. We will take a look at this database and will let you know.

Jeff Albion

SAP Active Global Support

jeff_albion
Employee
Employee
0 Kudos

Hello Bjarne,

This issue has been fixed in CR #774595, fixed in 12.0.1.4219 and 16.0.0.2073.

Thanks,

Jeff Albion

SAP Active Global Support

Former Member
0 Kudos

Very good!

When is this EBF available for download?

Regards,

Bjarne

Former Member
0 Kudos

I noticed that EBF 24131: 12.0.1 SP86 Build 4216 is released for download.

Is this issue fixed in that EBF?

Regards,

Bjarne

jeff_albion
Employee
Employee
0 Kudos

Hello Bjarne,

Unfortunately, no. You will need a build that is at 12.0.1.4219 or higher which will be contained in the next 12.0.1 Windows SP. There is a request to ensure that CR #774595 is included in the next 12.0.1 Windows x86/x64 release.

Thanks,

Jeff Albion

SAP Active Global Support

Answers (0)