Hi Madhu,
I think you can use the javascript client side command.
js try { db.command('select from index:V_TOPO_TYPE');} catch(e) { db.command
(create index V_TOPO_TYPE on V (TOPO_TYPE) NOTUNIQUE'); }
If the index does not exist the first command throws an Exception. Then, in
the catch you can create your index.
Hope it helps,
Fabrizio
On Friday, February 21, 2014 5:47:38 AM UTC, madhu wrote:
>
> Hi Everyone,
>
> Can anyone please give the query to create Index if not exist?
>
> For example: create index V_TOPO_TYPE on V (TOPO_TYPE) NOTUNIQUE;
> I want to create the indexes using a script file. If user executes the
> script again, it should not throw any exception.
>
> Thanks,
> Madhu
>
--
---
You received this message because you are subscribed to the Google Groups
"OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.