[ https://issues.apache.org/jira/browse/DRILL-3090?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16730409#comment-16730409 ]
Vitalii Diravka commented on DRILL-3090: ---------------------------------------- I confirm that the issue is still the same on Drill 1.15.0 version wtih SqlLine 1.6.0 version. {code} 0: jdbc:drill:zk=local> !script file3 Saving command script to " /tmp/drill/bin/file3". Enter "script" with no arguments to stop it. 0: jdbc:drill:zk=local> select * from sys.drillbits; +-------------+------------+---------------+------------+------------+----------+------------------+---------+ | hostname | user_port | control_port | data_port | http_port | current | version | state | +-------------+------------+---------------+------------+------------+----------+------------------+---------+ | vitalii-pc | 31010 | 31011 | 31012 | 8047 | true | 1.15.0-SNAPSHOT | ONLINE | +-------------+------------+---------------+------------+------------+----------+------------------+---------+ 1 row selected (0.076 seconds) 0: jdbc:drill:zk=local> !script Script closed. Enter "run /tmp/drill/bin/file3" to replay it. {code} {code} vitalii@vitalii-pc:/tmp$ cat /tmp/drill/bin/file3 select * from sys.drillbits; !script {code} {code} 0: jdbc:drill:zk=local> !run /tmp/drill/bin/file3 1/2 select * from sys.drillbits; +-------------+------------+---------------+------------+------------+----------+------------------+---------+ | hostname | user_port | control_port | data_port | http_port | current | version | state | +-------------+------------+---------------+------------+------------+----------+------------------+---------+ | vitalii-pc | 31010 | 31011 | 31012 | 8047 | true | 1.15.0-SNAPSHOT | ONLINE | +-------------+------------+---------------+------------+------------+----------+------------------+---------+ 1 row selected (0.085 seconds) 2/2 !script Usage: script <file name> Aborting command set because "force" is false and command failed: "!script" {code} > sqlline : save SQL to script file and replay from script, results in error > -------------------------------------------------------------------------- > > Key: DRILL-3090 > URL: https://issues.apache.org/jira/browse/DRILL-3090 > Project: Apache Drill > Issue Type: Bug > Components: Client - CLI > Affects Versions: 1.0.0 > Environment: ffbb9c7adc6360744bee186e1f69d47dc743f73e > Reporter: Khurram Faraaz > Priority: Minor > Fix For: Future > > > Save a SQL query to a script file and replay the SQL from the script file > using !run, on sqlline prompt throws error. We should not see the error when > we replay the SQL from the script file. > {code} > 0: jdbc:drill:schema=dfs.tmp> !script file3 > Saving command script to "/opt/mapr/drill/drill-1.0.0/bin/file3". Enter > "script" with no arguments to stop it. > 0: jdbc:drill:schema=dfs.tmp> select * from sys.drillbits; > +------------+------------+--------------+------------+------------+ > | hostname | user_port | control_port | data_port | current | > +------------+------------+--------------+------------+------------+ > | centos-04.qa.lab | 31010 | 31011 | 31012 | false | > | centos-02.qa.lab | 31010 | 31011 | 31012 | false | > | centos-01.qa.lab | 31010 | 31011 | 31012 | false | > | centos-03.qa.lab | 31010 | 31011 | 31012 | true | > +------------+------------+--------------+------------+------------+ > 4 rows selected (0.176 seconds) > 0: jdbc:drill:schema=dfs.tmp> !script > Script closed. Enter "run /opt/mapr/drill/drill-1.0.0/bin/file3" to replay it. > 0: jdbc:drill:schema=dfs.tmp> !run /opt/mapr/drill/drill-1.0.0/bin/file3 > 1/2 select * from sys.drillbits; > +------------+------------+--------------+------------+------------+ > | hostname | user_port | control_port | data_port | current | > +------------+------------+--------------+------------+------------+ > | centos-04 | 31010 | 31011 | 31012 | false | > | centos-02 | 31010 | 31011 | 31012 | false | > | centos-01 | 31010 | 31011 | 31012 | false | > | centos-03 | 31010 | 31011 | 31012 | true | > +------------+------------+--------------+------------+------------+ > 4 rows selected (0.178 seconds) > 2/2 !script > Usage: script <filename> > Aborting command set because "force" is false and command failed: "!script" > {code} > I looked at the contents of file3 under /opt/mapr/drill/drill-1.0.0/bin > There seems to be an additional/extra "!script" in the file. > {code} > [root@centos-01 bin]# cat file3 > select * from sys.drillbits; > !script > [root@centos-01 bin]# > {code} -- This message was sent by Atlassian JIRA (v7.6.3#76005)