Group: StrataFrame Users
Posts: 235,
Visits: 1.6K
|
I am getting an error adding a record to a table that does not have a primary key. The message states that I cannot insert a command because PrimaryKeyisAutoincremented = true and the PrimaryKeyField is not a valid auro-increment data type.
The table does not have a Primary Key or autoincrementing primary key set to Auto increment.
Any Ideas?
Sample code below.
'-- Create a new record .NewRow() 'Save Log Record LocHL7Data.MessageID = System.Guid.NewGuid.ToString() 'Loc_PID_SEG_BO.MessageID 'LocHL7Data.MessageSize = oMsg. LocHL7Data.VendorVersion = oMsg.VendorVersion LocHL7Data.VendorName = oMsg.VendorName LocHL7Data.MsgControl = sCrlID LocHL7Data.PartnerAPP = "" LocHL7Data.DateLoaded = System.DateTime.Now.ToString LocHL7Data.HL7Message = oMsg.HL7 LocHL7Data.SegmentCount = oMsg.SegmentCount LocHL7Data.MsgType = sMsgType1
'-- Save the record If .Save() <> MicroFour.StrataFrame.Data.SaveUndoResult.Success Then MsgBox("Save Failed...") End If End With
|