| Modifier and Type | Field and Description |
|---|---|
protected Set<String> |
alias |
protected String |
database |
protected String |
displayName |
protected Pair3<Long,Long,String> |
endPosition |
protected String |
fullName |
protected String |
name |
protected String |
parent |
protected Set<Pair<Pair3<Long,Long,String>,Pair3<Long,Long,String>>> |
positions |
protected String |
schema |
protected String |
server |
protected Pair3<Long,Long,String> |
startPosition |
| Constructor and Description |
|---|
Table(String tableName) |
Table(TCustomSqlStatement stmt,
TObjectName viewName) |
Table(TObjectName tableName) |
Table(TTable table) |
Table(TTable table,
String tableName) |
| Modifier and Type | Method and Description |
|---|---|
void |
addColumn(TableColumn column) |
void |
addColumnsFromSQLEnv() |
void |
addProcess(Process process) |
void |
clearDynamicTemplate()
Withdraws a dynamic-template mark.
|
void |
endFieldDeclaration()
Ends the declaration
openFieldDeclaration(long, long) started. |
TableColumn |
findColumn(String columnName) |
FieldDeclaration |
getActiveFieldDeclaration()
The declaration a read of the statement being analyzed is validated against; null when there is none.
|
String |
getAlias() |
Set<String> |
getAliasList() |
Object |
getBindingKey()
Binding identity, separate from legacy display getters: the table's identity under the
analysis's identifier rules (
getCanonicalIdentity()) with the legacy folded name bound
alongside, or the legacy name alone for a table the rules give no identity. |
List<String> |
getCandidateTables() |
QualifiedCanonKey |
getCanonicalIdentity()
The table's identity under the analysis's identifier rules: BigQuery's captured key, else a key
minted from the composed name's segments, each read in the form it arrived in.
|
QualifiedCanonKey |
getCanonicalIdentityAs(ESQLDataObjectType role)
The table's identity read in another object role of the same level (
dotSynonyms for a name that may
name a synonym): the same segments, forms and rules as getCanonicalIdentity(), the last segment under
that role's rules. |
List<TableColumn> |
getColumns() |
List<TableColumn> |
getColumnsWithFieldPaths()
The columns as the output lists them: each column followed by the field path nodes below it.
|
String |
getCurrentAlias() |
String |
getDatabase() |
String |
getDataSourceName()
The external data source a file path is read through (BULK INSERT ...
|
protected String |
getDefaultDatabase() |
protected String |
getDefaultSchema() |
protected String |
getDefaultServer() |
String |
getDisplayName() |
EndpointIntroduction |
getEndpointIntroduction() |
EndpointKind |
getEndpointKind() |
Pair3<Long,Long,String> |
getEndPosition() |
List<TableColumn> |
getFieldPathColumns()
The field path nodes, read-only: they are added by the field-path constructor only, which keeps the index.
|
TableColumn |
getFieldPathNode(FieldNodeKey key)
The field path node with identity
key, or null. |
String |
getFileFormat() |
String |
getFileType() |
String |
getFullName() |
long |
getId() |
QualifiedCanonKey |
getIdentifierKey() |
TableColumn |
getLoadColumn() |
String |
getLocation() |
String |
getName() |
String |
getNormalizedName()
Delimiter-normalized, dialect-aware form of
getName() (brackets / quotes
stripped per identifier segment). |
String |
getParent() |
String |
getPathUri()
The URI of a file path when it differs from its name: the data source's LOCATION joined with the path the
statement names; null when the URI is the name.
|
Set<Pair<Pair3<Long,Long,String>,Pair3<Long,Long,String>>> |
getPositions() |
String |
getProcedureId() |
List<Process> |
getProcesses() |
TableRelationRows |
getRelationRows() |
String |
getSchema() |
String |
getServer() |
TCustomSqlStatement |
getSqlStatement() |
String |
getStarStmt() |
Pair3<Long,Long,String> |
getStartPosition() |
SubType |
getSubType() |
TTable |
getTableObject() |
String |
getTemplatedParts()
Which identifier segments of
getName() were assembled at runtime, pipe-joined
outermost-first ("db", "db|name", ...); null when this endpoint
is not runtime-templated. |
boolean |
hasSQLEnv() |
boolean |
hasSubquery() |
boolean |
isAmbiguousUnqualifiedTable() |
boolean |
isArrayRelation() |
boolean |
isConstant() |
boolean |
isCreatedInSql()
Whether this endpoint is created by the analyzed SQL.
|
boolean |
isCreateTable() |
boolean |
isCursor() |
boolean |
isDatabase() |
boolean |
isDataSource() |
boolean |
isDetermined() |
boolean |
isDynamicTemplate()
True when this endpoint's identifier was assembled at runtime by a dynamic-SQL fold.
|
boolean |
isExternal() |
boolean |
isFromDDL() |
boolean |
isPath() |
boolean |
isPseudo() |
boolean |
isResolved()
Existing schema/model resolution state, exposed under the endpoint-classification
name.
|
boolean |
isSchema() |
boolean |
isSequence() |
boolean |
isStage() |
boolean |
isStream() |
boolean |
isTarget() |
static boolean |
isTsqlFamilyVendor(EDbVendor vendor)
Authoritative
EndpointKind, computed on access from the current (raw)
name and the active dialect. |
boolean |
isVariable() |
boolean |
isView() |
void |
markDynamicTemplate(String parts,
boolean identityTemplated)
Records that this endpoint's identifier was assembled at runtime by a dynamic-SQL
fold.
|
FieldDeclaration |
openFieldDeclaration(long created,
long dropped)
Starts the declaration of the CREATE TABLE statement
created, which the DROP TABLE dropped
ends (FieldDeclaration.NEVER_DROPPED when none does). |
void |
removeColumn(String columnName) |
void |
removeColumn(TableColumn column) |
void |
removeProcess(Process process) |
void |
setAlias(String alias) |
void |
setArrayRelation(boolean arrayRelation) |
void |
setConstant(boolean isConstant) |
void |
setCreatedInSql(boolean createdInSql) |
void |
setCreateTable(boolean isCreateTable) |
void |
setCreateTable(boolean isCreateTable,
boolean fromDDL) |
void |
setCurrentAlias(String currentAlias) |
void |
setDatabase(boolean isDatabase) |
void |
setDatabase(String database) |
void |
setDataSource(boolean dataSource) |
void |
setDataSourceName(String dataSourceName) |
void |
setDetermined(boolean isDetermined) |
void |
setDisplayName(String displayName) |
void |
setEndpointIntroduction(EndpointIntroduction endpointIntroduction)
Records how the endpoint was introduced.
|
void |
setExternal(boolean isExternal) |
void |
setFileFormat(String fileFormat) |
void |
setFileType(String fileType) |
void |
setFromDDL(boolean fromDDL) |
void |
setHasSQLEnv(boolean hasSQLEnv) |
void |
setLoadColumn(TableColumn column)
Makes
column the table's load column rather than one of its columns. |
void |
setLocation(String location) |
void |
setName(String name) |
void |
setParent(String parent) |
void |
setPath(boolean isPath) |
void |
setPath(boolean isPath,
boolean defaultQualifiers)
Marks a file path.
|
void |
setPathUri(String pathUri) |
Pair<Pair3<Long,Long,String>,Pair3<Long,Long,String>> |
setPosition(TCustomSqlStatement stmt) |
Pair<Pair3<Long,Long,String>,Pair3<Long,Long,String>> |
setPosition(TObjectName tableName) |
Pair<Pair3<Long,Long,String>,Pair3<Long,Long,String>> |
setPosition(TTable table) |
void |
setProcedureId(String procedureId) |
void |
setPseudo(boolean isPseudo) |
void |
setSchema(boolean isSchema) |
void |
setSequence(boolean sequence) |
void |
setStage(boolean isStage) |
void |
setStarStmt(String starStmt) |
void |
setStream(boolean isStream) |
void |
setSubType(SubType subType) |
void |
setTarget(boolean isTarget) |
void |
setVariable(boolean isVariable) |
void |
setView(boolean isView) |
protected void |
updateTableName(boolean supportCatalog,
boolean supportSchema) |
protected String displayName
protected Pair3<Long,Long,String> startPosition
protected Pair3<Long,Long,String> endPosition
public Table(TCustomSqlStatement stmt, TObjectName viewName)
public Table(TObjectName tableName)
public QualifiedCanonKey getIdentifierKey()
public Object getBindingKey()
getCanonicalIdentity()) with the legacy folded name bound
alongside, or the legacy name alone for a table the rules give no identity.public QualifiedCanonKey getCanonicalIdentity()
public QualifiedCanonKey getCanonicalIdentityAs(ESQLDataObjectType role)
dotSynonyms for a name that may
name a synonym): the same segments, forms and rules as getCanonicalIdentity(), the last segment under
that role's rules. A per-object profile may give synonyms rules of their own, so a synonym is matched in its
own role. Null when the rules give the name no identity.public TCustomSqlStatement getSqlStatement()
public void addColumnsFromSQLEnv()
protected String getDefaultServer()
protected String getDefaultSchema()
protected String getDefaultDatabase()
public boolean isAmbiguousUnqualifiedTable()
getCandidateTables().public List<String> getCandidateTables()
testdb.s1.orders,
testdb.s2.orders) when this reference is ambiguous across
schemas, or null when the reference resolved normally.protected void updateTableName(boolean supportCatalog, boolean supportSchema)
public long getId()
public Pair3<Long,Long,String> getStartPosition()
public Pair3<Long,Long,String> getEndPosition()
public List<TableColumn> getColumns()
public void addColumn(TableColumn column)
public List<TableColumn> getFieldPathColumns()
public boolean isArrayRelation()
public void setArrayRelation(boolean arrayRelation)
public TableColumn getFieldPathNode(FieldNodeKey key)
key, or null.public FieldDeclaration openFieldDeclaration(long created, long dropped)
created, which the DROP TABLE dropped
ends (FieldDeclaration.NEVER_DROPPED when none does). Until endFieldDeclaration(), the
declared fields recorded are this declaration's.public void endFieldDeclaration()
openFieldDeclaration(long, long) started.public FieldDeclaration getActiveFieldDeclaration()
public List<TableColumn> getColumnsWithFieldPaths()
public TableColumn getLoadColumn()
public void setLoadColumn(TableColumn column)
column the table's load column rather than one of its columns.public TTable getTableObject()
public String getFullName()
public boolean hasSubquery()
public String getDatabase()
public TableRelationRows getRelationRows()
public boolean isCreateTable()
public void setCreateTable(boolean isCreateTable, boolean fromDDL)
public void setCreateTable(boolean isCreateTable)
public boolean isView()
public void setView(boolean isView)
public boolean isPseudo()
public void setPseudo(boolean isPseudo)
public boolean isExternal()
public void setExternal(boolean isExternal)
public boolean isStage()
public void setStage(boolean isStage)
public boolean isSequence()
public void setSequence(boolean sequence)
public boolean isVariable()
public void setVariable(boolean isVariable)
public boolean isConstant()
public void setConstant(boolean isConstant)
public boolean isTarget()
public void setTarget(boolean isTarget)
public String getProcedureId()
public void setProcedureId(String procedureId)
public boolean isPath()
public void setPath(boolean isPath)
public void setPath(boolean isPath, boolean defaultQualifiers)
defaultQualifiers false the analysis defaults (the database and schema a USE or
an Option sets) stay off it, since a file is no object of a database (SQL Server BULK INSERT, Mantis 4962); the
file-path database and schema options still apply.public boolean isCursor()
public String getLocation()
public void setLocation(String location)
public String getDataSourceName()
public void setDataSourceName(String dataSourceName)
public String getPathUri()
public void setPathUri(String pathUri)
public String getFileType()
public void setFileType(String fileType)
public String getDisplayName()
public void setDisplayName(String displayName)
public String getFileFormat()
public void setFileFormat(String fileFormat)
public List<Process> getProcesses()
public void addProcess(Process process)
public void removeProcess(Process process)
public void setSubType(SubType subType)
public SubType getSubType()
public boolean isStream()
public void setStream(boolean isStream)
public boolean isSchema()
public void setSchema(boolean isSchema)
public void setDatabase(String database)
public boolean isDatabase()
public void setDatabase(boolean isDatabase)
public boolean isDataSource()
public void setDataSource(boolean dataSource)
public String getStarStmt()
public void setStarStmt(String starStmt)
public void setHasSQLEnv(boolean hasSQLEnv)
public boolean hasSQLEnv()
public String getCurrentAlias()
public void setCurrentAlias(String currentAlias)
public Set<String> getAliasList()
public boolean isDetermined()
public void setDetermined(boolean isDetermined)
public boolean isFromDDL()
public void setFromDDL(boolean fromDDL)
public boolean isCreatedInSql()
isDetermined(); true for CREATE TABLE / SELECT INTO / CTAS / clone
targets even when the defining query's schema could not be resolved.public void setCreatedInSql(boolean createdInSql)
public EndpointIntroduction getEndpointIntroduction()
public void setEndpointIntroduction(EndpointIntroduction endpointIntroduction)
public boolean isResolved()
isDetermined() exactly; introduces no new resolution logic.public String getNormalizedName()
public void markDynamicTemplate(String parts, boolean identityTemplated)
parts is the outermost-first, pipe-joined set of affected name
segments; identityTemplated says the hole reaches the leading character of
the object-name segment (so a #/@ prefix there is fold text, not a
real temp / table-variable marker). Additive across repeated marks: parts union,
identity ORs — one folded statement can reach the same endpoint twice.
Callers MUST only invoke this from inside a dynamic-fold context; see
EndpointKind.DYNAMIC_TEMPLATE.
public String getTemplatedParts()
getName() were assembled at runtime, pipe-joined
outermost-first ("db", "db|name", ...); null when this endpoint
is not runtime-templated. Lets a consumer match a templated skeleton against a
later-resolved concrete name without re-parsing the name text.public boolean isDynamicTemplate()
public void clearDynamicTemplate()
public static boolean isTsqlFamilyVendor(EDbVendor vendor)
EndpointKind, computed on access from the current (raw)
name and the active dialect. Quote-robust: each identifier segment is delimiter-
stripped before the #/##/@/tempdb tests. This
reads only the new classification; it never inspects or mutates subType.
§5.6 minimum scope: distinguishes T-SQL temp / global-temp / table-variable /
tempdb objects from plain catalog objects. CTE / derived / TVF / constant kinds
are deferred and reported as EndpointKind.UNKNOWN here.
public EndpointKind getEndpointKind()
public Pair<Pair3<Long,Long,String>,Pair3<Long,Long,String>> setPosition(TObjectName tableName)
public Pair<Pair3<Long,Long,String>,Pair3<Long,Long,String>> setPosition(TCustomSqlStatement stmt)
public TableColumn findColumn(String columnName)
public void removeColumn(TableColumn column)
public void removeColumn(String columnName)