This repository has been archived by the owner on Jul 16, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make db a parameter of serialize() (#208)
Previously, `db` is an attribute of class `Expr` and its value cannot be decided when init a new object. As a result, when the `Expr` is serialized, we need to explicitly bind it to a db to create functions or types. However, in some cases we forgot to do that, which lead to errros. To avoid forgotting this, this patch moves db to a parameter of `serialize()` and pass db to it each time we call it. This patch fixes the following bugs in `serialize()`: 1. Database is not found when trying to create a function or data type. 2. Star notation `*` is not serialized correctly in column fileds when expanding a composite type result. 3. `count(*)` returns wrong result when dataframe contains `None`. --------- Co-authored-by: Ruxue Zeng <[email protected]>
- Loading branch information
Showing
14 changed files
with
231 additions
and
252 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.