Рассматриваются вопросы оснащения модели ситуационно-ориентированной базы данных (СОБД) специализированными средствами для взаимодействия с системой управления баз данных MySQL. Представлена усовершенствованная модель СОБД, расширяющая возможности использования XML-данных, хра-нимых в реляционной СУБД MySQL. В результате модель СОБД получает средства для соединения с базой данных и управления ее объектами. Взаимо-действие заключается в создании баз данных и таблиц, а также в выборке дан-ных и их обновлении. Функции по организации взаимодействия реализованы на платформе интерпретатора динамической модели СОБД, разработанной с ис-пользованием технологий PHP. Модель имеет XML-представление и эквива-лентное представление в виде диаграмм.
Ключевые слова: веб-приложение, база данных, динамическая модель, NoSQL, XML, DOM, РНРВведение. На современном этапе развития NoSQL баз данных документоориентирован-ные базы работают с различными типами данных, которые основаны на открытых стандартах XML и JSON, поддерживаемых также в реляционных базах данных. Ситуационно-ориентированные базы данных (СОБД), относимые [1-6] к типу документоориентирован-ных, работают с различными так называемыми гетерогенными источниками данных [7][8][9][10][11][12][13]. В качестве источника данных могут выступать XML-данные, но хранящиеся не в привычном виде во внешней памяти, а в популярных СУБД, например MySQL. Доступ к таким XML-данным осуществляется опосредованно через принятые в MySQL запросы по стандарту SQL. В настоящее время СОБД не обладают инструментарием для получения доступа к данным через динамическую модель. Получение данных в приложении на основе СОБД осуществля-ется традиционными средствами с помощью различных функций на высокоуровневом языке программирования.Предлагается создать модель более высокого уровня абстракции на основе динамиче-ской модели СОБД путем обеспечения взаимодействия с MySQL.Соединение с сервером СУБД. В условиях, когда базы данных имеют различные на-правления развития и множество успешно реализованных видов систем управления, модель СОБД следует ориентировать на подключение к различным типам баз данных. Таким обра-зом, в модели указывается тип базы данных, например type = MySQL в элементе doc (рис. 1), что важно, так как лингвистические средства СУБД отличаются. Элемент doc, функциональное назначение которого -соединение с базой данных, выделяется в отдель-ный тип документов -conndoc. На doc-соединения этого типа ссылаются другие элемен-ты и документы модели из источников DPO, если требуется подключение к базе данных, в которой хранятся или собираются из одной или нескольких таблиц XML-документы, пред-варительно снабжаемые тегами XML, интерпретатором или функциями UDF, встроенными в СУБД. В зависимости от типа СУБД интерпретатор [13] задействует требуемый инстру-ментарий для взаимодействия с хостом, на котором установлена СУБД. Для создания соеди-нения с хостом СУБД в модели используется атрибут action, в котором декларируется