X-Git-Url: https://feistymeow.org/gitweb/?a=blobdiff_plain;f=database%2Fpatterns%2Fmysql%2Fopensim%2Fdb_queries_for_opensim.txt;fp=database%2Fpatterns%2Fmysql%2Fopensim%2Fdb_queries_for_opensim.txt;h=27dbde4310cd70188d047f4b4c03736e7fb92928;hb=c7498da918e9707b5fe8490236bbd64d8f35fc5b;hp=0000000000000000000000000000000000000000;hpb=e135361f5388839c28bf8d3db804e8558c7645a7;p=feisty_meow.git diff --git a/database/patterns/mysql/opensim/db_queries_for_opensim.txt b/database/patterns/mysql/opensim/db_queries_for_opensim.txt new file mode 100644 index 00000000..27dbde43 --- /dev/null +++ b/database/patterns/mysql/opensim/db_queries_for_opensim.txt @@ -0,0 +1,43 @@ + + +============== + +find all the tables that have a CreatorID column: + + SELECT DISTINCT TABLE_NAME + FROM INFORMATION_SCHEMA.COLUMNS + WHERE COLUMN_NAME IN ('CreatorId') + AND TABLE_SCHEMA='opensim'; + +=> yields assets inventoryitems prims primitems +as tables matching the column. + +(note: replacing all creator ids like below still did not secure total ownership +to fred; some things retained their original creator. how!?) + +============== + +replace all the creator ids with fred's id on ducky: + + update inventoryitems set creatorid = 'NEWGUID' + +=> do for each of the tables. + +============== + +checking to make sure the changes to creatorid took effect: + + select * from assets where creatorid != 'YOURGUID' + +=> there should be no matches after running a setting operation. + +============== + +if you have a more selective update to do, try replacing using a pattern: + + update assets set creatorid = replace(creatorid, 'OLDGUID', 'NEWGUID') + +============== + + +