column name without space and with sapce


  • Hi

    I need your suggestion that it in organisations we are not use any column that contains space in name ?

    Is it?

    let says

    we have column name [start time] is not used in organisations only [start_time](without sapce) column is only used ?

    Please suggest me.

    • Edited by BI_Support Tuesday, May 14, 2013 10:59 AM
    Tuesday, May 14, 2013 10:47 AM


All replies

  • Yes it is advised to be use column name without space. Since it leads to end in lot of issues when we forget to use [] in the column name.

    And it is also based on Organisation need,and the risk is on the organisation.

    Tuesday, May 14, 2013 10:50 AM
  • Hi

    yes as per standard [start_time](without sapce) column should be used .

    For Reference you can refer Naming convention and standard guide for SQL objects


    Tuesday, May 14, 2013 10:51 AM
  • If you are looking for more clarity on naming conventions, Refer Joe Celko's book.

    I do not have handy links right now.

    Please use Marked as Answer if my post solved your problem and use Vote As Helpful if a post was useful.

    Tuesday, May 14, 2013 11:00 AM
  • SQL Server does not have any problems if you use a space or any other uncommon character in the name a column or table. However, these identifiers need more care when using them, because they always need to be quoted (for example "start time" or "drag & drop" or "deleted?"). Therefore, I prefer naming conventions that forbid their use.

    When you are thinking about this narrow topic (whether or not to allow spaces in identifiers), you should really determine or pick a naming convention. I have not yet seen an SQL naming convention that prescribes/allows them.

    One possible naming convention for columns is to always use all lowercase ASCII characters (to avoid problems with case sensitivity and/or collation) and numbers (if desired), with underscore to separate words for readability, without prefixing the column with any table reference or data type reference, and without abbreviating words. For example: start_time, drag_and_drop and deleted.

    With that (above mentioned) naming convention, identifiers such as o_OrderID, dt_order_date, Order_ID and order_no would be invalid.


    Wednesday, May 15, 2013 12:41 PM
  • thanks for information friends

    Thursday, May 16, 2013 7:20 AM