| @@ -0,0 +1,16 @@ | |||||
| <% | |||||
| Class Migration_12_Alter_Kit_Table_With_Type | |||||
| Public Migration | |||||
| Public Sub Up | |||||
| Migration.Do "ALTER TABLE [Kit] " &_ | |||||
| "ADD [JobType] VARCHAR(50);" | |||||
| End Sub | |||||
| Public Sub Down | |||||
| Migration.Do "ALTER TABLE [Kit] " &_ | |||||
| "DROP COLUMN [JobType];" | |||||
| End Sub | |||||
| End Class | |||||
| Migrations.Add "Migration_12_Alter_Kit_Table_With_Type" | |||||
| %> | |||||
| @@ -40,6 +40,7 @@ Migrations.Tracing = false | |||||
| <!--#include file="Migration_09_Create_InkJetRecords_Table.asp"--> | <!--#include file="Migration_09_Create_InkJetRecords_Table.asp"--> | ||||
| <!--#include file="Migration_10_Alter_Tables_For_Relations.asp"--> | <!--#include file="Migration_10_Alter_Tables_For_Relations.asp"--> | ||||
| <!--#include file="Migration_11_Alter_Tables_For_Relations_FK.asp"--> | <!--#include file="Migration_11_Alter_Tables_For_Relations_FK.asp"--> | ||||
| <!--#include file="Migration_12_Alter_Kit_Table_With_Type.asp"--> | |||||
| <% | <% | ||||
| Sub HandleMigration | Sub HandleMigration | ||||
| putl "<b>Starting Version: " & Migrations.Version & "</b>" | putl "<b>Starting Version: " & Migrations.Version & "</b>" | ||||
| @@ -73,7 +73,7 @@ Dim JCode:JCode = Left(Filename,5) | |||||
| Dim oConn:Set oConn = WScript.CreateObject("ADODB.Connection") | Dim oConn:Set oConn = WScript.CreateObject("ADODB.Connection") | ||||
| oConn.ConnectionString = ConnectionString | oConn.ConnectionString = ConnectionString | ||||
| oConn.Open | oConn.Open | ||||
| oConn.Execute("Insert Into Kit ([JobNumber], [Jcode], [CreatedOn]) VALUES ('" & JobNumber & "','" & JCode & "',#" & Now() & "#);") | |||||
| oConn.Execute("Insert Into Kit ([JobNumber], [Jcode], [CreatedOn], [JobType]) VALUES ('" & JobNumber & "','" & JCode & "',#" & Now() & "#,'Purple Envelopes');") | |||||
| Dim rs : set rs = oConn.Execute("Select TOP 1 ID from Kit ORDER BY ID DESC") | Dim rs : set rs = oConn.Execute("Select TOP 1 ID from Kit ORDER BY ID DESC") | ||||
| Dim kitId : kitId = rs("ID").value | Dim kitId : kitId = rs("ID").value | ||||
| rs.close | rs.close | ||||
Powered by TurnKey Linux.