Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DROP and CREATE TABLE #1149

Closed
1 of 2 tasks
jarulraj opened this issue Sep 17, 2023 · 0 comments · Fixed by #1165
Closed
1 of 2 tasks

DROP and CREATE TABLE #1149

jarulraj opened this issue Sep 17, 2023 · 0 comments · Fixed by #1165
Assignees
Milestone

Comments

@jarulraj
Copy link
Member

Search before asking

  • I have searched the EvaDB issues and found no similar bug report.

Bug

-- No error if it the table exists
-- Error as the table does not exist
DROP TABLE StargazerDetails;

-- No error if it the table exists
-- No error if it the table does not exist
DROP TABLE IF EXISTS StargazerDetails;

-- Error if the table already exists
-- No error if the table does not exist
CREATE TABLE StargazerDetails AS
SELECT GithubUserdetails(github_username, "{github_pat}")
FROM StargazerList;

-- No error if the table already exists
-- No error if the table does not exist
CREATE TABLE IF NOT EXISTS StargazerDetails AS
SELECT GithubUserdetails(github_username, "{github_pat}")
FROM StargazerList;

Environment

Need to add unit tests for all four cases.

Are you willing to submit a PR?

  • Yes I'd like to help by submitting a PR!
@jarulraj jarulraj added this to the v0.3.5 milestone Sep 17, 2023
@gaurav274 gaurav274 assigned gaurav274 and unassigned xzdandy Sep 18, 2023
@xzdandy xzdandy linked a pull request Sep 19, 2023 that will close this issue
jarulraj pushed a commit that referenced this issue Sep 21, 2023
Cannot reproduce the bug but added robust testcases. 

#1149 The inconsistent behavior might be happening because of another
bug where we were creating a table even if the select query failed. We
have fixed that, so it may fix this bug as well.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

Successfully merging a pull request may close this issue.

3 participants