Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

function index like lower(column) #37783

Closed
cevin opened this issue May 24, 2019 · 1 comment
Closed

function index like lower(column) #37783

cevin opened this issue May 24, 2019 · 1 comment

Comments

@cevin
Copy link

cevin commented May 24, 2019

create unique index t3_uname on test3 (lower(username));
//error:invalid syntax: statement ignored: syntax error: unimplemented: unimplemented at or near ")"

<?php

$stmt = $pdo->prepare("select * from test3 where lower(username)  = :username");
$stmt->bindValue(':username',strtolower($_GET['username']));
$stmt->execute();
$stmt->fetchAll(PDO::FETCH_ASSOC);
@jordanlewis
Copy link
Member

Hi, you're looking for a "computed index": an index on an expression, not just a column. This feature is currently unsupported in CockroachDB and is tracked in #9682.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants