src/Database/QueryBuilder/StringBuilder.php
/**
	 * Formats the table name for use in a query.
	 *
	 * @param string $name
	 * @return string
	 */
Formats the table name for use in a query.
@param string $name
@return string
Formats the table name for use in a query . @param string $name @return string
public static function formatTableName($name) {
		$name = trim($name);
		$segments = explode('.', $name);
		if (count($segments) == 1) {
			return sprintf('`%s`', $segments[0]);
		}
		elseif (count($segments) == 2) {
			return sprintf('`%s`.%s', $segments[0], static::formatTableName($segments[1]));
		}
		return $name;
	}
public static function formatTableName ( $ name ) { $ name = trim ( $ name ) ; $ segments = explode ( '.' , $ name ) ; if ( count ( $ segments ) == 1 ) { return sprintf ( '`%s`' , $ segments [ 0 ] ) ; } elseif ( count ( $ segments ) == 2 ) { return sprintf ( '`%s`.%s' , $ segments [ 0 ] , static :: formatTableName ( $ segments [ 1 ] ) ) ; } return $ name ; }
Formats the table name for use in a query.
Formats the table name for use in a query .