Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

OLD DB or ODBC Error

Hi, I'm pretty new to PBI... I have a query that is pulling info from a Folder that we regularly load remittance files to. The files usually come in a standard format and have all the same columns ...
  • v-lid-msft's avatar
    6 years ago

    Hi Anonymous ,

     

    We suggest you to delete the URI in your Query.

     

    If you want the static column to use, we can add a selectcolumn function after source step, then the following steps will not have error if you get extra column in source:

     

    let
        Source = ,
        SelectWantedColumn = Table.SelectColumns(Source, Table.ToList(ColumnNameTable),MissingField.UseNull),
        #"Changed Type" = Table.TransformColumnTypes(SelectWantedColumn,{{"A", Int64.Type}, {"B", Int64.Type}, {"C", Int64.Type}, {"D", Int64.Type}})
    
    in
        #"Changed Type"

     

     

    The ColumnNameTable is from a EnterTable, you can also import it from a excel/csv file.

     


    BTW, pbix as attached.

     

    Best regards,

    Community Support Team _ Dong Li
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.