Database Reference
In-Depth Information
rowling@yahoo.com | someHashed#passwrd
(1 rows)
Tip
Downloading the example code
You can download the example code files for all Packt topics you have purchased from
your account at http://www.packtpub.com . If you purchased this topic elsewhere, you can
visit http://www.packtpub.com/support and register to have the files e-mailed directly to
you.
The application would generate uuid or you will get uuid from an existing record in the
blogs table based on a user's e-mail address or some other criteria. Here, just to be con-
cise, the uuid generation is left to Cassandra, and it is retrieved by running the SELECT
statement. Let's insert some posts to this blog:
# First post
cqlsh:weblog> INSERT INTO posts (id, blog_id, title,
content, tags, posted_on) VALUES (now(),
83cec740-22b1-11e4-a4f0-7f1a8b30f852, 'first post', 'hey
howdy!', {'random','welcome'}, 1407822921000);
cqlsh:weblog> SELECT * FROM posts;
blog_id | id | content |
posted_on | tags | title
------------+-----------+------------+--------------------------+-----------------------+------------
83cec... | 04722... | hey howdy! | 2014-08-12
11:25:21+0530 | {'random', 'welcome'} | first post
Search WWH ::




Custom Search