• -- Create Sample Partitioned Table

    CREATE TABLE OrderEvents (

    OrderCloseDate datetime not null,

    OrderNum int not null,

    [Status] char(2) null,

    StatusDate datetime not null)

    ON ps_FACT_DATA_DATE (MyDate)

    GO

    Msg 1911, Level 16, State 1, Line 2

    Column name 'MyDate' does not exist in the target table or view.

    Should the MyDate in the partitionscheme call be OrderCloseDate? or is the partitiondb.sql script including missing something else? I get an error running this portion of the script and figured it was because this column isn't part of the table so it can't partition on it.

    Thanks for looking,

    -Ryan