STSADM -o export/import is often used to split site collections into multiple pieces when they reached a certain limit. Or to do the vice versa and consolidate multiple site collections into one larger one. Both of these actions work fine as long as the migrated content does not use the publishing feature.
For site collections that make use of the publishing feature it is not supported to migrate root sites into sub sites or sub sites into root sites.
The reason for this limitation is that the publishing feature stores vital information like page layouts but also various properties like information about variation, reusable content and so on in the root site of a site collection.
When migrating a root site into a subsite the imported content will link to the new location of the previous root site. E.g. the page layout URLs will afterwards point to the page layouts library in the sub site and not of the root site which does not work as the publishing feature requires these items to be in the root site. So additional actions like moving the page layouts to the root site and adjusting all page layout urls would be required. Similar things would be required for variations and reusable content.
On the other hand when migrating a sub site to a root site it gets even worse: in this situation important content which was stored in the root site of the site collection is no longer available as the sub site does not contain the necessary information as they haven't been exported in the first place. So after importing the subsite as new root site items based on the publishing feature will be non functional.
Be aware that this limitation will also affect sites with custom features which store information outside the current site.
Valid migration scenarios when using the publishing feature are the following:
- export the site collection starting at the root site and import as root site into a new site collection
(using a custom application you can specify which sub sites to export if you would like to avoid to export all of them)
- export sub sites of the site collection and import them as sub sites into an existing site collection that has the publishing feature enabled