none
U-SQL External table error: 'Unable to cast object of type 'System.DBNull' to type 'System.Type'.'

    Question

  • Hello,

    I'm failing to create external tables to two specific tables,

    I already created few external tables with no issues,

    The only difference I can see between the failed and the successful external tables is that the tables that failed contains geography type columns, so I think this is the issue but i'm not sure.

    Anyway, this is the error I get when i deploy the U-SQL DB:

    Failed to connect to data source: 'SqlDbSource', with error(s): 'Unable to cast object of type 'System.DBNull' to type 'System.Type'.'

    This is the U-SQL code to create the external table:

    CREATE EXTERNAL TABLE IF NOT EXISTS [Data].[Devices]
    (
        [Id] int
    )
    FROM SqlDbSource LOCATION "[Data].[Devices]";

    Hope someone will come with solution or any idea to what could be the problem,

    Thanks in advance,


    Dor Meiri


    • Edited by Dor Meiri Wednesday, May 15, 2019 7:04 AM
    Wednesday, May 15, 2019 7:03 AM

All replies