This website uses cookies. By browsing this website, you consent to the use of cookies. Learn more.

Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

Highlighted
Good afternoon,

Is it possible to get the first character as 0? For example i have two numbers

24567 and 02456, so i tried the fonction get (x,0,1) but at the sacond case its giving to me "2" instead of "0", as well if i calculate the length, it will be "4" instead of "5". Which function should i use to get first 0 and the legth of characters as 5?

PS: I tried transfer my data to string and after use the function but it didnt work.

Thank you in advance! Anastasiia

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

Is it possible to get the first character as 0? For example i have two numbers

24567 and 02456, so i tried the fonction get (x,0,1) but at the sacond case its giving to me "2" instead of "0", as well if i calculate the length, it will be "4" instead of "5". Which function should i use to get first 0 and the legth of characters as 5?

PS: I tried transfer my data to string and after use the function but it didnt work.

Thank you in advance! Anastasiia

1 Solution

Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

Formula will always autocast when referencing the column directly, even if the storage type is string. To avoid that, replace x in your formula by strval("x")

So it would look like: substring(strval("x"),0,1)

1 Reply

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

Formula will always autocast when referencing the column directly, even if the storage type is string. To avoid that, replace x in your formula by strval("x")

So it would look like: substring(strval("x"),0,1)