You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+15-1Lines changed: 15 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -17,6 +17,7 @@ Table of Contents
17
17
-[Extracting The Schema](#extracting-the-schema)
18
18
-[Extracting The Query](#extracting-the-query)
19
19
-[Extracting The Port](#extracting-the-port)
20
+
-[Extracting The File Extension](#extracting-the-file-extension)
20
21
-[Extracting The TLD (Top-Level Domain)](#extracting-the-tld-top-level-domain)
21
22
-[Extracting The Sub Domain](#extracting-the-sub-domain)
22
23
-[Get Tranco Rank](#get-tranco-rank)
@@ -208,6 +209,20 @@ D SELECT extract_port('[::1]:6379') AS port;
208
209
└─────────┘
209
210
```
210
211
212
+
### Extracting The File Extension
213
+
214
+
This function extracts the file extension from a URL. It will return the file extension without the dot.
215
+
216
+
```sql
217
+
D SELECT extract_extension('http://example.com/image.jpg') AS ext;
218
+
┌─────────┐
219
+
│ ext │
220
+
│ varchar │
221
+
├─────────┤
222
+
│ jpg │
223
+
└─────────┘
224
+
```
225
+
211
226
### Extracting The TLD (Top-Level Domain)
212
227
213
228
This function extracts the top-level domain from a URL. This function will use the public suffix list to extract the TLD. Check the [Extracting The Main Domain](#extracting-the-main-domain) section for more information about the public suffix list.
@@ -373,7 +388,6 @@ D select * from netquack_version();
373
388
## Roadmap 🗺️
374
389
375
390
-[ ] Create a `TableFunction` for `extract_query_parameters` that return each key-value pair as a row.
0 commit comments