Skip to content

Conversation

@HappenLee
Copy link
Contributor

#4376 issue

Proposed changes

Describe the big picture of your changes here to communicate to the maintainers why we should accept this pull request. If it fixes a bug or resolves a feature request, be sure to link to that issue.

Types of changes

What types of changes does your code introduce to Doris?
Put an x in the boxes that apply

  • [] Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • [] Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • [] Documentation Update (if none of the other choices apply)
  • [] Code refactor (Modify the code structure, format the code, etc...)

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • I have create an issue on (Fix #ISSUE), and have described the bug/feature there in detail
  • Compiling and unit tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • If this change need a document change, I have updated the document
  • Any dependent changes have been merged

}

// Before we fix the problem utf8 encode sql query in SQLexecDirect
// we need to check some filter can not encode in asii code, like chinese
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

asii --> ascii

}

_tuple = reinterpret_cast<Tuple*>(tuple_buffer);
// Indicates whether there are more rows to process. Set in _hbase_scanner.next().
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

_hbase_scanner?


LOG(INFO) << "execute success:" << query << " column count:" << _field_num;

// check materialize num equeal _field_num
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

equeal -> equal

return Status::InternalError(msg.str());
}

std::string ODBCScanner::handle_diagnostic_record(SQLHANDLE hHandle,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add some comments

| DOUBLE | DOUBLE | |
| DATE | DATE | |
| DECIMAL | DECIMAL | |

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hll data type?
datetime data type?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mysql now do not support hll, i will add datetime type in doc


4. 通过Oracle访问出现乱码

尝试在BE启动脚本之中添加如下参数:`export NLS_LANG=AMERICAN_AMERICA.AL32UTF8`, 并重新启动所有BE
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个参数如果直接放到be的启动脚本里会有啥影响?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

不会有什么影响,但是原则上不使用oracle数据库的话是用不到这个环境变量的

ODBC_DISPOSE(_dbc, SQL_HANDLE_DBC, SQLDriverConnect(_dbc, NULL, (SQLCHAR*)_connect_string.c_str(), SQL_NTS,
NULL, 0, NULL, SQL_DRIVER_COMPLETE_REQUIRED), "driver connect");

LOG(INFO) << "connect success:";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add more detail informaton in log

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@morningman morningman added the kind/feature Categorizes issue or PR as related to a new feature. label Sep 1, 2020
// converting text data in MySQL cells to binary data.
virtual Status get_next(RuntimeState* state, RowBatch* row_batch, bool* eos);

// Close the _mysql_scanner, and report errors.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Modify the comment

// Now we only treat HLL, CHAR, VARCHAR as big column
static constexpr uint32_t BIG_COLUMN_SIZE_BUFFER = 65535;

static std::u16string utf8_to_wstring (const std::string& str)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
static std::u16string utf8_to_wstring (const std::string& str)
static std::u16string utf8_to_wstring(const std::string& str)

#### 2. 通过ODBC_Resource来创建ODBC外表 (推荐使用的方式)
```
create external resource "oracle_odbc"
properties
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indent

Copy link
Contributor

@morningman morningman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@morningman morningman added the approved Indicates a PR has been approved by one committer. label Sep 24, 2020
@morningman morningman merged commit a61d0de into apache:master Sep 25, 2020
caoyang10 pushed a commit to caoyang10/incubator-doris that referenced this pull request Oct 29, 2020
@yangzhg yangzhg mentioned this pull request Feb 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by one committer. kind/feature Categorizes issue or PR as related to a new feature.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants