Yes, you can bind parameters by name: ``` INSERT INTO songs (id, title, album, artist) VALUES (:id, :title, :album, :artist) ```
All DataStax drivers for Cassandra support this feature. In Java it looks like // prepare only once PreparedStatememt pstmt = session.prepare("INSERT INTO songs (id, title, album, artist) VALUES (:id, :title, :album, :artist)") // later BoundStatement stmt = new BoundStatement(pstmt); stmt.setLong("id", 1234); stmt.setString("title", "Example title"); On Mon, Sep 22, 2014 at 4:41 AM, Timmy Turner <timm.t...@gmail.com> wrote: > Looking through the CQL 3.1 grammar in Cassandra, I found a "':' ident" > alternative in the "value" rule (line 961). > > Is this for binding named parameters in prepared statements? Is this > currently supported by any of the drivers or in Cassandra (2.1) itself? > > Looking at the docs and the current Java driver it doesn't seem that way. > -- :- a) Alex Popescu Sen. Product Manager @ DataStax @al3xandru