Ignore Columns at destination

  • Hi !

    I have a query which gets 5 columns and i need to insert the 5 columns in table which has 7 columns at the destination .at the destination i was ignoring this columns but i was getting the error saying that it cannot insert null values in the destination table .Please advice how to insert 5 columns while rest of the 2 columns can be ignored .

    Thanks in advance

  • If the destination table has a NOT NULL constraint on the remaining two columns you need to insert the related values.

    Please talk to the DBA in charge what values are expected.



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • Or ask your DBA to set up default constraints.

    Need an answer? No, you need a question
    My blog at https://sqlkover.com.
    MCSE Business Intelligence - Microsoft Data Platform MVP

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply