ignite-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ilya Suntsov (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (IGNITE-6111) SQL: Add ability to do INSERT without specifying the column names
Date Fri, 09 Nov 2018 17:53:00 GMT

    [ https://issues.apache.org/jira/browse/IGNITE-6111?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16681752#comment-16681752
] 

Ilya Suntsov commented on IGNITE-6111:
--------------------------------------

I've found the problem that relates with this feature.

Step 1

{noformat}

19/23 CREATE TABLE CUSTOMER ( C_CUSTKEY INTEGER NOT NULL PRIMARY KEY, 
C_NAME VARCHAR(25) NOT NULL, 
C_ADDRESS VARCHAR(40) NOT NULL, 
C_NATIONKEY INTEGER NOT NULL, 
C_PHONE CHAR(15) NOT NULL, 
C_ACCTBAL DECIMAL(15,2) NOT NULL, 
C_MKTSEGMENT CHAR(10) NOT NULL, 
C_COMMENT VARCHAR(117) NOT NULL) 
WITH "atomicity=ATOMIC";

{noformat}

Step 2

{noformat}

Error: Failed to parse query. Column "1" not found; SQL statement:
INSERT INTO customer VALUES ("1","Customer#000000001","IVhzIApeRb ot,c,E","15","25-989-741-2988","711.56","BUILDING","to
the even, regular platelets. regular, ironic epitaphs nag e") [42122-197] (state=42000,code=1001)
java.sql.SQLException: Failed to parse query. Column "1" not found; SQL statement:
INSERT INTO customer VALUES ("1","Customer#000000001","IVhzIApeRb ot,c,E","15","25-989-741-2988","711.56","BUILDING","to
the even, regular platelets. regular, ironic epitaphs nag e") [42122-197]
 at org.apache.ignite.internal.jdbc.thin.JdbcThinConnection.sendRequest(JdbcThinConnection.java:750)
 at org.apache.ignite.internal.jdbc.thin.JdbcThinStatement.execute0(JdbcThinStatement.java:212)
 at org.apache.ignite.internal.jdbc.thin.JdbcThinStatement.execute(JdbcThinStatement.java:475)
 at sqlline.Commands.execute(Commands.java:814)
 at sqlline.Commands.sql(Commands.java:754)
 at sqlline.SqlLine.dispatch(SqlLine.java:646)
 at sqlline.SqlLine.runCommands(SqlLine.java:1681)
 at sqlline.Commands.run(Commands.java:1393)
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.lang.reflect.Method.invoke(Method.java:498)
 at sqlline.ReflectiveCommandHandler.execute(ReflectiveCommandHandler.java:38)
 at sqlline.SqlLine.dispatch(SqlLine.java:643)
 at sqlline.SqlLine.initArgs(SqlLine.java:427)
 at sqlline.SqlLine.begin(SqlLine.java:485)
 at sqlline.SqlLine.start(SqlLine.java:233)
 at sqlline.SqlLine.main(SqlLine.java:175)
Aborting command set because "force" is false and command failed: "INSERT INTO customer VALUES
("1","Customer#000000001","IVhzIApeRb ot,c,E","15","25-989-741-2988","711.56","BUILDING","to
the even, regular platelets. regular, ironic epitaphs nag e");"
Closing: org.apache.ignite.internal.jdbc.thin.JdbcThinConnection

{noformat}

> SQL: Add ability to do INSERT without specifying the column names
> -----------------------------------------------------------------
>
>                 Key: IGNITE-6111
>                 URL: https://issues.apache.org/jira/browse/IGNITE-6111
>             Project: Ignite
>          Issue Type: Task
>          Components: sql
>    Affects Versions: 2.1
>            Reporter: Alexandr Fedotov
>            Assignee: Vladimir Ozerov
>            Priority: Major
>              Labels: usability
>             Fix For: 2.4
>
>
> Having the following classes
> {code:java}
> class PersonKey {
>     private Long id;
> }
> class Person {
>     private Long id;
>     private String name;
> }
> {code}
> with proper configuration it should be possible to execute queries 
> of the following type passing {{id}} and {{name}} as the arguments
> {code:sql}"insert into Person values(?,?)"{code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message