| От | karl@tecc.co.uk (Karl Orbell) |
|---|---|
| Тема | position(text,text) function |
| Дата | |
| Msg-id | slrn9loctm.qsr.karl@azrael.tecc.co.uk обсуждение |
| Ответы |
Re: position(text,text) function
|
| Список | pgsql-sql |
I'm having trouble using the position function, it's a simple built-in function.
It returns the index of a substring within a main string.
But, I just can't get it to work, it always gives this silly parser error.
I've tried it in a variety of ways with variables instead of constants casting
to text and using it in other contexts, (ie. in functions, not just in a
select). What am I doing wrong? Is this not the correct syntax for a two
argument function?
test=# select position('hello','el');
ERROR: parser: parse error at or near ","
Karl Orbell.
В списке pgsql-sql по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера