Database Reference
In-Depth Information
"756716f7-2e54-4715-9f00-91dcbea6cf50;");
for (Row row : results) {
Sys-
tem.out.println(String.format("%-7s\t%-7s\t%-7s\t%-7s
\n%s",
"Ticker", "Price", "Change", "PCT",
"........+........+........+........"));
Sys-
tem.out.println(String.format("%-7s\t%0.2f\t%0.2f\t%0.2f",
row.getString("ticker"),
row.getDecimal("current_price"),
row.getDecimal("current_change"),
row.getFloat("current_change_percent")
));
}
}
public static void main(String[] args) {
SampleApp client = new SampleApp();
client.connect("127.0.0.1");
client.createSchema();
client.loadData();
client.printResults();
client.close();
}
}
C#
The C# driver uses the CQL 3 Binary Protocol and is currently maintained
by DataStax. To get started, first create a new console application in C# using
.NET Framework 4.5. In the Package Manager Console window, type Install-
Package CassandraCSharpDriver .
To start this example, we will first need to include our using directives so that
we have access to our Cassandra driver. We will then namespace our application
Search WWH ::




Custom Search