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

fix(core): fix column not found error after column rename #3368

Merged
merged 3 commits into from May 19, 2023

Conversation

ideoma
Copy link
Collaborator

@ideoma ideoma commented May 19, 2023

The PR fixes the column version not set when the column is renamed. Specific to non-partitioned tables only.

Found by fuzz test runs.

io.questdb.griffin.SqlException: [0] [2]: could not open read-only [file=/tmp/junit1029390315418332203/dbRoot/y~/default/new_col_17.d.14]
	at io.questdb.griffin.SqlException.position(SqlException.java:107)
	at io.questdb.griffin.SqlOptimiser.openReaderAndEnumerateColumns(SqlOptimiser.java:2496)
	at io.questdb.griffin.SqlOptimiser.enumerateTableColumns(SqlOptimiser.java:1770)
	at io.questdb.griffin.SqlOptimiser.enumerateTableColumns(SqlOptimiser.java:1775)
	at io.questdb.griffin.SqlOptimiser.optimise(SqlOptimiser.java:4646)
	at io.questdb.griffin.SqlCompiler.compileExecutionModel0(SqlCompiler.java:1172)
	at io.questdb.griffin.SqlCompiler.compileExecutionModel(SqlCompiler.java:1161)
	at io.questdb.griffin.SqlCompiler.compileUsingModel(SqlCompiler.java:1244)
	at io.questdb.griffin.SqlCompiler.compileInner(SqlCompiler.java:1213)
	at io.questdb.griffin.SqlCompiler.compile(SqlCompiler.java:207)
	at io.questdb.test.tools.TestUtils.assertEquals(TestUtils.java:425)
	at io.questdb.test.griffin.O3MaxLagFuzzTest.testFuzz00(O3MaxLagFuzzTest.java:149)
	at io.questdb.test.griffin.O3MaxLagFuzzTest.testFuzz0(O3MaxLagFuzzTest.java:158)

@ideoma
Copy link
Collaborator Author

ideoma commented May 19, 2023

[PR Coverage check]

😍 pass : 2 / 2 (100.00%)

file detail

path covered line new line coverage
🔵 io/questdb/cairo/TableWriter.java 2 2 100.00%

@bluestreak01 bluestreak01 merged commit f935efc into master May 19, 2023
20 checks passed
@bluestreak01 bluestreak01 deleted the fix-rename-column-part-by-none-tbl branch May 19, 2023 17:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants