ATG’s documentation suggests running startSQLRepository to export repositories. However this is an older solution that works well with SOLID and DAS but not so easily with Oracle and JBoss. Oracle uses its own JDBC jar which you have to add to the CLASSPATH before running startSQLRepository. JBoss uses JNDI and real DataSource’s to connect to the database. But this doesn’t work with startSQLRepository so you have to set up a separate ATG server with fake DataSources to run with startSQLRepository.
All of this is to say it’s a pain to use startSQLRepository. The much simpler method is to navigate to the repository in your Dynamo admin (e.g. http://localhost:8080/dyn/admin). Then in the “Run XML Operation Tags on the Repository” textbox enter the command
[xml]<export-items />[/xml]
Or if you want to export only certain item-descriptors:
[xml]<export-items item-descriptors="authors, books" />[/xml]
And if you want to ensure you only get a certain item-descriptor without any referenced item-descriptors:
[xml]<export-items item-descriptors="books" skip-references="true" />[/xml]
You can then save the outputted XML to an XML file and then later paste the contents of this XML file to the same textbox to import the repository items.
For more information please see the <export-items> section in the SQL Repository Reference chapter of the ATG Repository Guide.
Can this work with a large repository such as ProfileAdapterRepository?
I’m trying to do this right now but it looks like chrome just stops the export and I don’t see any results.
Yeah for large repositories it can sometimes hang or even fail if the amount of data is too large. In that case it would be better to use startSQLRepository.bat or startSQLRepository but that is more difficult to set up.