(
&self,
name: PartialItemName,
)
| 668 | } |
| 669 | |
| 670 | pub fn allocate_temporary_qualified_name( |
| 671 | &self, |
| 672 | name: PartialItemName, |
| 673 | ) -> Result<QualifiedItemName, PlanError> { |
| 674 | // Compare against the MZ_TEMP_SCHEMA constant directly instead of calling |
| 675 | // get_schema(), because with lazy temporary schema creation, the temp |
| 676 | // schema may not exist yet. (This is similar to what `allocate_temporary_full_name` was |
| 677 | // doing already before making temporary schemas lazy.) |
| 678 | if let Some(schema_name) = name.schema { |
| 679 | if schema_name != mz_repr::namespaces::MZ_TEMP_SCHEMA { |
| 680 | return Err(PlanError::InvalidTemporarySchema); |
| 681 | } |
| 682 | } |
| 683 | |
| 684 | Ok(QualifiedItemName { |
| 685 | qualifiers: ItemQualifiers { |
| 686 | database_spec: ResolvedDatabaseSpecifier::Ambient, |
| 687 | schema_spec: SchemaSpecifier::Temporary, |
| 688 | }, |
| 689 | item: name.item, |
| 690 | }) |
| 691 | } |
| 692 | |
| 693 | // Creates a `ResolvedItemName::Item` from a `GlobalId` and an |
| 694 | // `UnresolvedItemName`. |
no outgoing calls
no test coverage detected