Esempio n. 1
0
 /**
  *
  * @return XMLASchema
  */
 public function getSchema()
 {
     if (empty($this->schema)) {
         $catalog = $this->databaseMetaData->getCatalogObjects()->get($this->getCatalog());
         $this->schema = $catalog->getSchemas()->get(0);
     }
     return $this->schema;
 }
Esempio n. 2
0
 private function lookupCube(XMLADatabaseMetaData $databaseMetaData, $cubeName)
 {
     $catalog = $databaseMetaData->getCatalogObjects()->get($this->statement->getConnection()->getCatalog());
     foreach ($catalog->getSchemas() as $schema) {
         foreach ($schema->getCubes() as $cube) {
             if ($cubeName == $cube->getName()) {
                 return $cube;
             }
             if ($cubeName == '[' . $cube->getName() . ']') {
                 return $cube;
             }
         }
     }
     return null;
 }