Your question qualifies as duplicate of that question about "Multiple major modes in one buffer".
Therefore it should be closed.
Nevertheless, since you are new to Emacs I give you below a modified version of the code block from the accepted answer of the duplicate that should solve your problem.
Copy that code block into your init file, which is most often one of
If you use that code block make sure that you have installed
You can check or run the installation of
mmm-mode with the menu item
Options->Manage Emacs Packages.
See the manual page about Emacs packages for other ways of managing packages.
:front "<FnTable\\( ID=\".*\"\\)?>\n"
(setq mmm-global-mode 'maybe)
(mmm-add-mode-ext-class 'nxml-mode nil 'nxml-sql)