Query regarding retrival of data

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Query regarding retrival of data

Master Mind
Hi all,
Greeting for this day.

I have successfully inserted data into the riak database using riak-python client and currently, I'm using single node configuration. I'm refering to http://riak-python-client.readthedocs.io/en/2.2.0/client.html this website for a tutorial but I'm having lots of problem in getting the clear solution.

my system configuration is:
OS - Ubuntu Trusty LTS
Python - 2.7.6
Riak KV - 2.1.4

So my question is that now:

Q) I want to see what are all the buckets that are present in my database at this moment?
Q) If I know the name of the buckets then is there any way to retrieve all the keys that bucket have?
Q) Is there any possibility by which we can specify the WHERE condition as we do in SQL? 

Please help me in this.
Any documentation or website or any kind of help is apprecited.

Mr. Coder,
MTECH in Distributed Database, 
National Institute of Technology. INDIA

_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Reply | Threaded
Open this post in threaded view
|

RE: Query regarding retrival of data

Travis Kirstine

 

 

From: riak-users [mailto:[hidden email]] On Behalf Of Master Mind
Sent: April-05-17 3:03 PM
To: [hidden email]
Subject: Query regarding retrival of data

 

Hi all,

Greeting for this day.

 

I have successfully inserted data into the riak database using riak-python client and currently, I'm using single node configuration. I'm refering to http://riak-python-client.readthedocs.io/en/2.2.0/client.html this website for a tutorial but I'm having lots of problem in getting the clear solution.

 

my system configuration is:

OS - Ubuntu Trusty LTS

Python - 2.7.6

Riak KV - 2.1.4

 

So my question is that now:

 

Q) I want to see what are all the buckets that are present in my database at this moment?

 

 

http://riak-python-client.readthedocs.io/en/2.2.0/client.html#riak.client.RiakClient.stream_buckets

 

 

 

Q) If I know the name of the buckets then is there any way to retrieve all the keys that bucket have?

 

http://riak-python-client.readthedocs.io/en/2.2.0/client.html#riak.client.RiakClient.get_keys

http://riak-python-client.readthedocs.io/en/2.2.0/client.html#riak.client.RiakClient.stream_keys

 

 

Q) Is there any possibility by which we can specify the WHERE condition as we do in SQL?

 

Yes and no.  The basic .get will return a contents where bucket= and key=

 

http://riak-python-client.readthedocs.io/en/2.2.0/client.html#riak.client.RiakClient.get

 

Beyond that you would need to setup riak search

 

http://docs.basho.com/riak/kv/2.2.1/developing/usage/search/

 

or secondary indexes

 

http://docs.basho.com/riak/kv/2.2.1/using/reference/secondary-indexes/

 

 

 

 

 

Please help me in this.

Any documentation or website or any kind of help is apprecited.

 

Mr. Coder,

MTECH in Distributed Database, 

National Institute of Technology. INDIA


_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com