Hi Dean, For altering tables, I used to do as Nicolas, either manually creating ALTER TABLE scripts or just using Enterprise Manager to generate the script when manually changing the dev tables. You obviously have to be aware of the underlying data if you are changing the type or length of a field and the effects that this might have on it and any indexes. But generally I now use SQL Compare from
Red Gate to synchronise various development, QA and production database. This will compare all the database structures for you, show what differences there are and allow you to chooes which to synchronise and generate the scripts for you to apply now or later. SQL Data Compare allows you to do the same to the data. So now I generate and build all database structures to an empty database and then use SQL Compare to synchronise, but also to capture changes that I've made directly to the dev database when tuning stored procedures - to make sure those changes get updated to the model. For the DDL, I believe you are correct on NULL being the default and the optionality triple only affects programs which query this at gen time. As Nicolas has said, you can use the 'DBMS script SRC' for the identity column, but I'll admit that I have not used this where Plex is doing inserts and updates - as weel as not inserting to this field, I'll imagine attempted updates to this field may also fail (the SQL Plex generates updates all fields regardless of whether they have actually changed or not). In addition to Nicolas' hints I'd add that I make extensive use of Select Where - the where clause is generated based on the restrict, position variables, specified filters, plus hand coded SQL fragments. We also often have entities scoping views that I have not figured out how to model in Plex which do plenty of complicated joins and aggregations, case statements etc - the views are not built, but the entity has the associated scripts attached. Make friends with SQL Profiler, it really helps to see the SQL you are executing against the database when you are getting no rows back. You can execute the SQL in Management Studio to work out where it has gone wrong. If performance is in issue learning to understand the excecution plan of the SQL statements is a must also.