How can we help you today? How can we help you today?
slowder

Activity overview

Latest activity by slowder

Here's an example where the data generator struggles. CREATE TABLE [dbo].[Story] ( StoryID INT IDENTITY(1,1) NOT NULL , FamilyID INT NOT NULL , Name NVARCHAR(255) NOT NULL , [Description] NVARCHAR(MAX) NULL --redacted columns , [LocationID] INT NULL , [PersonCategoryID] INT NOT NULL , [Published] BIT NOT NULL DEFAULT(1) , CONSTRAINT PK_Story__StoryID_FamilyID PRIMARY KEY (StoryID, FamilyID) , CONSTRAINT FK_Story_Family__FamilyID FOREIGN KEY (FamilyID) REFERENCES Family(FamilyID) , CONSTRAINT FK_Story_Location__LocationID_FamilyID FOREIGN KEY(LocationID, FamilyID) REFERENCES Location(LocationID, FamilyID) , CONSTRAINT FK_Story_PersonCategory__PersonCategoryID_FamilyID FOREIGN KEY (PersonCategoryID, FamilyID) REFERENCES Person.PersonCategory(PersonCategoryID, FamilyID) ) The problem is around the foreign keys on the FamilyID, LocationID and PersonCategoryID. Values in the LocationID field have to be for the same family (tenant). Values in the PersonCategoryID also have to be in the same tenant. So the data generator would have to understand, if I put 1 in the FamiylID, then I have to choose LocationIDs and PersonCategoryIDs that also have familyID of 1. I haven't found a way to do that with data generator. Also, I've found if you have a self-referencing key (say "parentStoryID" and that points back to the PK in this table, StoryID + FamilyID, that fails too. Any ideas on how to configure for these situations? / comments
Here's an example where the data generator struggles.CREATE TABLE [dbo].[Story] ( StoryID INT IDENTITY(1,1) NOT NULL , FamilyID INT NOT NULL , Name NVARCHAR(25...
0 votes
Data Generator and Check Contstraints.
Given the check constraint: CONSTRAINT c_BillingTransaction__InvoiceID_ReceiptID CHECK (InvoiceID IS NULL OR ReceiptID IS NULL) Is there an easy way to have data generator understand if you fill in...
2 followers 2 comments 0 votes
Multi-part keys
Let's say you have a table with three columns that make up a unique constraint, Each of the columns is a foreign key to another table. You want to use data generator to insert data into those colu...
2 followers 5 comments 0 votes