Bugs item #2807336, was opened at 2009-06-16 21:27
Message generated for change (Comment added) made by stmane
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=482468&aid=2807336&group_id=56967

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: SQL/Core
Group: MonetDB5 CVS Head
Status: Open
Resolution: None
Priority: 5
Private: Yes
Submitted By: Stefan de Konink (skinkie)
Assigned to: Niels Nes (nielsnes)
Summary: UPDATE Assertion `re->type == e_column'

Initial Comment:
>mserver5: ../../../src/server/rel_select.mx:4289: rel_select_exp: Assertion 
>`re->type == e_column' failed.

Is caused by:
update anbi set kvk = (select kvk from kvk,anbi where lower(naam) = 
lower(bedrijfsnaam) and lower(plaats) = lower(vestigingsplaats));

Now I know this query might not be valid... but I was toying around :)

----------------------------------------------------------------------

>Comment By: Stefan Manegold (stmane)
Date: 2009-06-24 14:59

Message:
... in other words, the actual problem is that the error in the sub query
is not handled/propagated properly ...


----------------------------------------------------------------------

Comment By: Stefan Manegold (stmane)
Date: 2009-06-24 14:57

Message:
sql>select kvk.kvk from kvk,anbi where lower(naam) = lower(bedrijfsnaam)
and lower(plaats) = lower(vestigingsplaats);
0 tuples
sql>update anbi set kvk = (select kvk.kvk from kvk,anbi where lower(naam)
= lower(bedrijfsnaam) and lower(plaats) = lower(vestigingsplaats));
Rows affected 0
sql>


----------------------------------------------------------------------

Comment By: Stefan Manegold (stmane)
Date: 2009-06-24 14:54

Message:
sql>CREATE TABLE "sys"."anbi" ( "naam" varchar(256), "vestigingsplaats"
varchar(32), "beschikking" date, "intrekking" date, kvk bigint);
0 tuples
sql>CREATE TABLE "sys"."kvk" ("kvk" bigint, "bedrijfsnaam" varchar(255),
"adres" varchar(64), "postcode" varchar(6), "plaats" varchar(32), "type"
varchar(16));
0 tuples
sql>select kvk from kvk,anbi where lower(naam) = lower(bedrijfsnaam) and
lower(plaats) = lower(vestigingsplaats);
!SELECT: identifier 'kvk' unknown or ambiguous
0 tuples
sql>



----------------------------------------------------------------------

Comment By: Stefan de Konink (skinkie)
Date: 2009-06-24 14:19

Message:
Sorry, that was a production copy. Adding kvk bigint to the schema
definition of anbi works.


sql>CREATE TABLE "sys"."anbi" ( "naam" varchar(256), "vestigingsplaats"
varchar(32), "beschikking" date, "intrekking" date, kvk bigint);
0 tuples
sql>CREATE TABLE "sys"."kvk" ("kvk" bigint, "bedrijfsnaam" varchar(255),
"adres" varchar(64), "postcode" varchar(6), "plaats" varchar(32), "type"
varchar(16));
0 tuples
sql>update anbi set kvk = (select kvk from kvk,anbi where lower(naam) =
lower(bedrijfsnaam) and lower(plaats) = lower(vestigingsplaats));
MAPI  = mone...@localhost:50000
ACTION= read_line
QUERY = update anbi set kvk = (select kvk from kvk,anbi where lower(naam)
=
ERROR = Connection terminated


----------------------------------------------------------------------

Comment By: Sjoerd Mullender (sjoerd)
Date: 2009-06-24 14:12

Message:
Sorry:
sql>update anbi set kvk = (select kvk from kvk,anbi where lower(naam) =
lower(bedrijfsnaam) and lower(plaats) = lower(vestigingsplaats));
!UPDATE: no such column 'anbi.kvk'

The schema does not match the query.

----------------------------------------------------------------------

Comment By: Stefan de Konink (skinkie)
Date: 2009-06-24 12:00

Message:
CREATE TABLE "sys"."anbi" (
        "naam" varchar(256),
        "vestigingsplaats" varchar(32),
        "beschikking" date,
        "intrekking" date
);

CREATE TABLE "sys"."kvk" (
        "kvk" bigint,
        "bedrijfsnaam" varchar(255),
        "adres" varchar(64),
        "postcode" varchar(6),
        "plaats" varchar(32),
        "type" varchar(16)
);

The data is available with Niels, but I have kindly requested not to
incorporate the entire database in a public test suite until further
notice.

----------------------------------------------------------------------

Comment By: Sjoerd Mullender (sjoerd)
Date: 2009-06-24 11:57

Message:
database schema?
Presumably we don't need data, but this cannot be tested without a
database schema.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=482468&aid=2807336&group_id=56967

------------------------------------------------------------------------------
_______________________________________________
Monetdb-bugs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-bugs

Reply via email to