Community technical support mailing list was retired 2010 and replaced with a professional technical support team. For assistance please contact: Pre-sales Technical support via email to sales@march-hare.com.
On Wed, 29 Apr 2009 06:07:52 +1000, "Arthur Barrett" <arthur.barrett at march-hare.com> wrote: >Bo, > > >> What is your script SQL for updating an MSSQLServer database? >> I mean the text of the update script, so I can see what may be >> possible to do? > >In your install directory, in the sub-directory sql, the file >upgrade_1_mssql.sql. There appears to be a bug in the MSSQL script where >it does not rename the Date column to StartTime. > Well, now that you mention it my database is sort of screwed up and I never understood why until now... Here is the script you refernce: -- Mssql upgrade to v2 Create Table %PREFIX%SchemaVersion (Version Integer); Insert Into %PREFIX%SchemaVersion (Version) Values (2); Alter Table %PREFIX%SessionLog Add Column EndTime DateTime; EXEC sp_rename '%PREFIX%SessionLog.Date', 'StartTime', 'COLUMN' This %PREFIX% stuff is presumably replaced by CVSNT with something, which in my case turns out to be "CVSNT." The result is that new tables are created in the databse with similar but different names. I now have duplicates in the database: dbo.CommitLog AND CVSNT.CommitLog dbo.HistoryLog AND CVSNT.HistoryLog CVSNT.SchemaVersion dbo.SessionLog AND CVSNT.SessionLog dbo.TagLog AND CVSNT.TagLog The column names are different between the tables too, for instance in SessionLog I have Date (dbo) and StartTime (CVSNT) There are various other differences as well.... How did this happen? There is now data spread over two sets of tables, not the best approach. But in the new table the Date column has been replaced by StartTime. -- /Bo (Bo Berglund, developer in Sweden)