public string GetObjectName(string name, bool quote = true) { if (name.Contains(" ") && name.IndexOf('[') == -1 || ReservedWords.ContainsKey(name)) { return("[" + name + "]"); } else { return(name); } }
public string GetObjectName(string name, bool quote = true) { name = getObjectName(name); if (string.IsNullOrWhiteSpace(name)) { return(name); } if (name.Contains(" ") && name.IndexOf('"') == -1 || ReservedWords.ContainsKey(name)) { return("\"" + name + "\""); } else { return(name); } }