none
question about datatable.select RRS feed

  • Question

  • Hello,

    I would like to know if it's possible to do:
    DataTable.Select( "customer name = 'john'");  <=== the column names is composed of two words.

    For me it doesn't seem like working.
    Tuesday, February 5, 2008 5:08 PM

Answers

  • Hello,

     

    Put the name of the table between brackets and it's working with SQL Server

     

    DataTable.Select("[customer name] = 'john'");

     

    For every T-SQL instruction, if you are using a table or a field of which names are composed with several words , put these names between brackets

     

    Have a nice day

     

    Tuesday, February 5, 2008 8:45 PM