{"action":"closed","issue":{"url":"https://api.github.com/repos/codefollower/Lealone/issues/57","labels_url":"https://api.github.com/repos/codefollower/Lealone/issues/57/labels{/name}","comments_url":"https://api.github.com/repos/codefollower/Lealone/issues/57/comments","events_url":"https://api.github.com/repos/codefollower/Lealone/issues/57/events","html_url":"https://github.com/codefollower/Lealone/issues/57","id":19090584,"number":57,"title":"2个lealone使用join查询的问题","user":{"login":"xiang82","id":5293552,"avatar_url":"https://avatars.githubusercontent.com/u/5293552?v=3","gravatar_id":"","url":"https://api.github.com/users/xiang82","html_url":"https://github.com/xiang82","followers_url":"https://api.github.com/users/xiang82/followers","following_url":"https://api.github.com/users/xiang82/following{/other_user}","gists_url":"https://api.github.com/users/xiang82/gists{/gist_id}","starred_url":"https://api.github.com/users/xiang82/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xiang82/subscriptions","organizations_url":"https://api.github.com/users/xiang82/orgs","repos_url":"https://api.github.com/users/xiang82/repos","events_url":"https://api.github.com/users/xiang82/events{/privacy}","received_events_url":"https://api.github.com/users/xiang82/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/codefollower/Lealone/labels/bug","name":"bug","color":"fc2929"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2013-09-06T06:38:52Z","updated_at":"2015-04-11T08:56:04Z","closed_at":"2015-04-11T08:56:04Z","body":"下面是2个lealone使用join查询的问题：\r\n\r\n1. 使用create hbase table的方式建表，插入数据后进行如下inner join查询，发现执行过程中会报错，请问能否解决？\r\nselect a.date_time,b.date_time \r\nfrom cht01 a join cht02 b \r\non a.date_time=b.date_time \r\nwhere a._rowkey_='1970-01-01 00:00:01'\r\nand b._rowkey_='1970-01-01 00:00:01';\r\n\r\n报错信息：\r\nError: General error: \"com.codefollower.lealone.hbase.command.RetryableCommand$RetriesExhaustedException: java.lang.ArrayIndexOutOfBoundsException: -2\"; SQL statement:\r\nselect a.date_time,b.date_time \r\nfrom cht01 a join cht02 b \r\non a.date_time=b.date_time \r\nwhere a._rowkey_='1970-01-01 00:00:01'\r\nand b._rowkey_='1970-01-01 00:00:01' [50000-171]\r\nSQLState:  HY000\r\nErrorCode: 50000\r\n\r\n（但是使用create table方式建的表，执行同样的查询，就能执行成功：\r\nselect a.date_time,b.date_time \r\nfrom ct01 a join ct02 b \r\non a.date_time=b.date_time \r\nwhere a.date_time='1970-01-01 00:00:01'\r\nand b.date_time='1970-01-01 00:00:01';）\r\n\r\n2. 既然create table方式建表可以使用join查询，那么我加大数据量后继续测试，大约5千万和1亿的2张表，还是执行相同的查询，发现耗时会非常久，效率很低，感觉像做了一次全表匹配。请问是怎么回事？\r\nselect a.date_time,b.date_time \r\nfrom ct50m a join ct100m b \r\non a.date_time=b.date_time \r\nwhere a.date_time='1970-01-01 00:00:01'\r\nand b.date_time='1970-01-01 00:00:01';"}}