Tuesday, August 15, 2017

Data Stores


Wanna do CRUD against a Google sheet using Python? Sounds dirty? Create, Retrieve, Update and Delete are the core actions one takes against a recording medium, with the devil, as always, in the details. Do we use SQL (Structured Query Language)? Maybe so.

In the above video, however, we're putting a resource in the cloud, a tabular data set, and letting a single user consult it, or mess it up, using Python. When a dataset is read-only, or, as we often say, immutable, the chances for panic attack are a lot less. But what if disparate users write and read at the same time? Are transactions atomic? That's where we talk about ACID, in addition to CRUD.

Precisely because spreadsheets are such a useful tool, and easily comprehended, there's a temptation to go overboard and overuse them. The key skill, then, is to recognize when a spreadsheet might be sufficient, and when it's potentially a dangerous shortcut, a decision that might come back to haunt one down the road.

Python has long participated in the office automation environment within Windows.

The win32all extension gave Python the power to talk to the Microsoft Office suite and even to define COM objects, later renamed to ActiveX.

Indeed, the wish to have ActiveX objects collaborate yet have different source code language origins, was a primary motivator of .NET (dot net), as was the wish to give C# (C sharp) a playing field it could dominate happily.