How can I reliably export a database diagram to a TSQL script file? More specifically, how can I tell which rows in the dtproperties table are for which diagram? I don't want to blindly copy the whole dtProperties table because I don't want to overwrite everything in the destination server. Also I have tried this and it didn't work for me. I see the diagram listed under the Diagrams node, but when I tried to open one of them I get an error about being out of memory.