Get Nth element of an array that returns from "string_to_array()" function

I am searching for a way to access to the Nth element of an array which is a result of string_to_array() function in PostgreSQL. For example,

Assume that a cell contains the string value: "A simple example" . If I use string_to_array() function, I will have an array of three strings as ('A','simple','example'). Now, without storing (I mean, on the fly) I want to access the 2nd element of this array, which is 'simple'.

During my googling, I saw an example to access the last element of the array but this barely solved my problem.

Is there a way to do this?


select (string_to_array('1,2,3,4',','))[2];

Need Your Help

How do I split a string by strings and include the delimiters using .NET?

c# .net string

There are many similar questions, but apparently no perfect match, that's why I'm asking.

Secure hash and salt for PHP passwords

php security passwords hash protection

It is currently said that MD5 is partially unsafe. Taking this into consideration, I'd like to know which mechanism to use for password protection.