# SELECT \* ILIKE EXCLUDE REPLACE RENAME

Database vendors are competing to see who can come up with the most features for **SELECT \***. **Snowflake** is not lagging and supports as many as 4 modifiers for **SELECT \***:\
**ILIKE EXCLUDE REPLACE RENAME**

We all know that **SELECT \*** is bad. Now it's 4 times worse :)\
Ok, 3. You can't use them all together (either **ILIKE** or **EXCLUDE**).

But the most disgusting modifier is **REPLACE**. It allows you to replace one column with any expression. Good luck debugging, dudes :)

What happens to lineage when using these modifiers? A few examples are collected here: [in 4.select-ilike-exclude-replace-rename.1.sql](https://github.com/dwh-dev/data-lineage-challenge/blob/main/snowflake/4.select-ilike-exclude-replace-rename/sql/4.select-ilike-exclude-replace-rename.1.sql)

Take a look at one of them:

```sql
CREATE TABLE t19(
  id INT,
  c1 BOOLEAN, 
  c2 BOOLEAN,
  c3 BOOLEAN,
  c4 BOOLEAN,
  c12c BOOLEAN
);
CREATE TABLE t20(
  c5 BOOLEAN, 
  c6 BOOLEAN
);

CREATE VIEW v20 AS
  SELECT
    * 
      ILIKE 'c%'
      REPLACE (a.c1 OR b.$2 AS c1)
      RENAME c1 AS c0
  FROM t19 a, t20 b
;
```

At [**Dwh.dev**](https://dwh.dev/), we display it like this:

<figure><img src="/files/W7S5jm9yqA1r0JVcgJq4" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.dwh.dev/snowflake-sql-syntax-and-behavior/select-ilike-exclude-replace-rename.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
