Skip to content

Adding missing dependency and .gitignore #5

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

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 0 additions & 29 deletions .classpath

This file was deleted.

40 changes: 40 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
target/
bin/
.settings/
.classpath
.project
*.iml
*.log
**/.m2/*
**/*.zip
tags
.idea
**/*.iml
bundles/**/META-INF/
bundles/**/git.properties
git.properties
**/git.properties
**/*.jar
**/*.esa
**/*.class
**/*.log
**/*.out
**/*.trace
**/*.rar
**/*.gz
**/*.tar
**/*.zip
**/*.exe
**/*.dmg
**/*.pdf
**/*.bak
**/*.html
**/*.css
**/test-output/
**/test-output/**
**/*.html
**/*.m2
**/*.json
!bundles/**/src/main/resources/META-INF/
.DS_Store
*~
23 changes: 0 additions & 23 deletions .project

This file was deleted.

6 changes: 0 additions & 6 deletions .settings/org.eclipse.jdt.core.prefs

This file was deleted.

5 changes: 5 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -94,5 +94,10 @@
<artifactId>postgresql</artifactId>
<version>9.1-901.jdbc4</version>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-api</artifactId>
<version>5.9.2</version>
</dependency>
</dependencies>
</project>
53 changes: 36 additions & 17 deletions src/unnesting/UnnestingVisitor.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
import catalog.CatalogManager;
import catalog.info.ColumnInfo;
import catalog.info.TableInfo;
import config.LoggingConfig;
import config.NamingConfig;
import expressions.normalization.CollectReferencesVisitor;
import expressions.normalization.CopyVisitor;
Expand Down Expand Up @@ -97,33 +98,38 @@ public class UnnestingVisitor extends CopyVisitor implements SelectVisitor {
*
* @param plainSelect extract columns for this query's FROM clause
*/
void treatSimpleFrom(PlainSelect plainSelect) {
void treatSimpleFrom(final PlainSelect plainSelect) {
// Retrieve fields to update
Set<ColumnRef> curScopeCols = scopeCols.peek();
Map<String, List<String>> curAliasToCols = aliasToCols.peek();
final Set<ColumnRef> curScopeCols = scopeCols.peek();
final Map<String, List<String>> curAliasToCols = aliasToCols.peek();
// Get all items in FROM clause
List<FromItem> fromItems = FromUtil.allFromItems(plainSelect);
final List<FromItem> fromItems = FromUtil.allFromItems(plainSelect);
// Iterate over base tables in FROM clause
for (FromItem fromItem : fromItems) {
for (final FromItem fromItem : fromItems) {
if (fromItem instanceof Table) {
// Extract table and alias name (defaults to table name)
Table table = (Table)fromItem;
String tableName = table.getName().toLowerCase();
String alias = table.getAlias()!=null?
final Table table = (Table)fromItem;
final String tableName = table.getName().toLowerCase();
final String alias = table.getAlias()!=null?
table.getAlias().getName():tableName;
// Extract associated column references
TableInfo tableInfo = CatalogManager.currentDB.
final TableInfo tableInfo = CatalogManager.currentDB.
nameToTable.get(tableName);
// Update scope and mappings
List<String> curAliasCols = new ArrayList<>();
final List<String> curAliasCols = new ArrayList<>();
curAliasToCols.put(alias, curAliasCols);
for (ColumnInfo colInfo : tableInfo.nameToCol.values()) {
String colName = colInfo.name;
// Update current scope
curScopeCols.add(new ColumnRef("", colName));
curScopeCols.add(new ColumnRef(alias, colName));
// Update current alias to column mapping
curAliasCols.add(colName);

if (null == tableInfo.nameToCol) {
log("Table information not available for table " + tableName + ". Data may be missing / not in file location.");
} else {
for (ColumnInfo colInfo : tableInfo.nameToCol.values()) {
final String colName = colInfo.name;
// Update current scope
curScopeCols.add(new ColumnRef("", colName));
curScopeCols.add(new ColumnRef(alias, colName));
// Update current alias to column mapping
curAliasCols.add(colName);
}
}
}
}
Expand Down Expand Up @@ -574,4 +580,17 @@ public void visit(SubSelect subSelect) {
}
}
}

/**
* @FIXME: bad code duplication for missing logging capability / library
* Outputs given string if expression logging
* is activated.
*
* @param logEntry entry to log
*/
void log(String logEntry) {
if (LoggingConfig.EXPRESSIONS_VERBOSE) {
System.out.println(logEntry);
}
}
}
1 change: 0 additions & 1 deletion target/.gitignore

This file was deleted.

6 changes: 0 additions & 6 deletions target/classes/.gitignore

This file was deleted.

5 changes: 0 additions & 5 deletions target/classes/META-INF/MANIFEST.MF

This file was deleted.

This file was deleted.

98 changes: 0 additions & 98 deletions target/classes/META-INF/maven/mcts_db_tests/mcts_db_tests/pom.xml

This file was deleted.

Binary file removed target/classes/benchmark/BenchAndVerify.class
Binary file not shown.
Binary file removed target/classes/benchmark/BenchUtil.class
Binary file not shown.
Binary file removed target/classes/buffer/BufferManager.class
Binary file not shown.
Binary file removed target/classes/catalog/CatalogManager.class
Binary file not shown.
Binary file removed target/classes/catalog/info/ColumnInfo.class
Binary file not shown.
Binary file removed target/classes/catalog/info/DbInfo.class
Binary file not shown.
Binary file removed target/classes/catalog/info/TableInfo.class
Binary file not shown.
Binary file removed target/classes/catalog/stats/DbStats.class
Binary file not shown.
Binary file removed target/classes/catalog/stats/TableStats.class
Binary file not shown.
Binary file removed target/classes/compression/Compressor.class
Binary file not shown.
Binary file removed target/classes/config/CheckConfig.class
Binary file not shown.
Binary file removed target/classes/config/GeneralConfig.class
Binary file not shown.
Binary file removed target/classes/config/IndexingMode.class
Binary file not shown.
Binary file removed target/classes/config/JoinConfig.class
Binary file not shown.
Binary file removed target/classes/config/LoggingConfig.class
Binary file not shown.
Binary file removed target/classes/config/NamingConfig.class
Binary file not shown.
Binary file removed target/classes/config/ParallelConfig.class
Binary file not shown.
Binary file removed target/classes/config/PathConfig.class
Binary file not shown.
Binary file removed target/classes/config/PreConfig.class
Binary file not shown.
Binary file removed target/classes/config/StartupConfig.class
Binary file not shown.
Binary file removed target/classes/console/SkinnerCmd.class
Binary file not shown.
Binary file removed target/classes/data/ColumnData.class
Binary file not shown.
Binary file removed target/classes/data/Dictionary.class
Binary file not shown.
Binary file removed target/classes/data/DoubleData.class
Binary file not shown.
Binary file removed target/classes/data/IntData.class
Binary file not shown.
Binary file removed target/classes/data/LongData.class
Binary file not shown.
Binary file removed target/classes/data/StringData.class
Binary file not shown.
Binary file removed target/classes/ddl/TableCreator.class
Binary file not shown.
Binary file removed target/classes/diskio/DiskUtil.class
Binary file not shown.
Binary file removed target/classes/diskio/LoadCSV.class
Binary file not shown.
Binary file removed target/classes/diskio/PathUtil.class
Binary file not shown.
Binary file removed target/classes/execution/Master.class
Binary file not shown.
Binary file removed target/classes/expressions/ExpressionInfo.class
Binary file not shown.
Binary file removed target/classes/expressions/SkinnerDeprVisitor.class
Binary file not shown.
Binary file removed target/classes/expressions/SkinnerVisitor.class
Binary file not shown.
Binary file removed target/classes/expressions/VisitorUtil.class
Binary file not shown.
Binary file removed target/classes/expressions/aggregates/AggInfo.class
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed target/classes/expressions/printing/PgPrinter.class
Binary file not shown.
Binary file not shown.
Binary file removed target/classes/expressions/typing/TypeVisitor.class
Binary file not shown.
Binary file removed target/classes/indexing/DoubleIndex.class
Binary file not shown.
Binary file removed target/classes/indexing/Index.class
Binary file not shown.
Binary file removed target/classes/indexing/IndexChecker.class
Binary file not shown.
Binary file removed target/classes/indexing/Indexer.class
Binary file not shown.
Binary file removed target/classes/indexing/IntIndex.class
Binary file not shown.
Binary file removed target/classes/joining/JoinProcessor.class
Binary file not shown.
Binary file removed target/classes/joining/join/DummyJoin.class
Binary file not shown.
Binary file removed target/classes/joining/join/JoinDoubleWrapper.class
Binary file not shown.
Binary file removed target/classes/joining/join/JoinIndexWrapper.class
Binary file not shown.
Binary file removed target/classes/joining/join/JoinIntWrapper.class
Binary file not shown.
Binary file removed target/classes/joining/join/JoinMove.class
Binary file not shown.
Binary file removed target/classes/joining/join/MultiWayJoin.class
Binary file not shown.
Binary file removed target/classes/joining/join/OldJoin.class
Binary file not shown.
Binary file removed target/classes/joining/plan/JoinOrder.class
Binary file not shown.
Binary file removed target/classes/joining/plan/LeftDeepPlan.class
Binary file not shown.
Binary file removed target/classes/joining/progress/Progress.class
Binary file not shown.
Binary file not shown.
Binary file removed target/classes/joining/progress/State.class
Binary file not shown.
Binary file removed target/classes/joining/result/JoinResult.class
Binary file not shown.
Binary file removed target/classes/joining/result/ResultNode.class
Binary file not shown.
Binary file removed target/classes/joining/result/ResultTuple.class
Binary file not shown.
Binary file not shown.
Binary file removed target/classes/joining/uct/SelectionPolicy.class
Binary file not shown.
Binary file removed target/classes/joining/uct/UctNode.class
Binary file not shown.
Binary file removed target/classes/operators/Filter.class
Binary file not shown.
Binary file removed target/classes/operators/Group.class
Binary file not shown.
Binary file removed target/classes/operators/GroupBy.class
Binary file not shown.
Binary file removed target/classes/operators/IndexFilter.class
Binary file not shown.
Binary file removed target/classes/operators/IndexTest.class
Binary file not shown.
Binary file removed target/classes/operators/MapRows.class
Binary file not shown.
Binary file removed target/classes/operators/Materialize.class
Binary file not shown.
Binary file removed target/classes/operators/MinMaxAggregate.class
Binary file not shown.
Binary file removed target/classes/operators/OrderBy.class
Binary file not shown.
Binary file removed target/classes/operators/RowRange.class
Binary file not shown.
Binary file removed target/classes/operators/SumAggregate.class
Binary file not shown.
Binary file removed target/classes/postprocessing/PostProcessor.class
Binary file not shown.
Binary file removed target/classes/preprocessing/Context.class
Binary file not shown.
Binary file removed target/classes/preprocessing/Preprocessor.class
Binary file not shown.
Binary file removed target/classes/preprocessing/PreprocessorTest.class
Binary file not shown.
Binary file removed target/classes/print/RelationPrinter.class
Binary file not shown.
Binary file removed target/classes/query/AggregationType.class
Binary file not shown.
Binary file removed target/classes/query/ColumnRef.class
Binary file not shown.
Binary file removed target/classes/query/QueryInfo.class
Binary file not shown.
Binary file removed target/classes/query/SQLexception.class
Binary file not shown.
Binary file removed target/classes/query/from/FromUtil.class
Binary file not shown.
Binary file removed target/classes/query/select/SelectUtil.class
Binary file not shown.
Binary file removed target/classes/query/where/WhereUtil.class
Binary file not shown.
Binary file removed target/classes/statistics/JoinStats.class
Binary file not shown.
Binary file removed target/classes/statistics/PostStats.class
Binary file not shown.
Binary file removed target/classes/statistics/PreStats.class
Binary file not shown.
Binary file removed target/classes/testing/CompressionTest.class
Binary file not shown.
Binary file removed target/classes/testing/StringTests.class
Binary file not shown.
Binary file removed target/classes/tools/CopyData.class
Binary file not shown.
Binary file removed target/classes/tools/CreateDB.class
Binary file not shown.
Binary file removed target/classes/types/JavaType.class
Binary file not shown.
Binary file removed target/classes/types/SQLtype.class
Binary file not shown.
Binary file removed target/classes/types/TypeUtil.class
Binary file not shown.
Binary file removed target/classes/udf/UdfIntEquals.class
Binary file not shown.
Binary file removed target/classes/unnesting/UnnestingVisitor.class
Binary file not shown.
Binary file removed target/classes/visualization/TreePlotter.class
Binary file not shown.