Register and share your invite link to earn from video plays and referrals.

Search results for DataModeling
DataModeling community
One keyword maps to one global community path.
Create community
People
Not Found
Tweets including DataModeling
# Elasticsearch Features and Practical Usage 📦 No need to lock down a table schema first — the moment you throw JSON at it, your data is usable. An Elasticsearch index is a document-oriented data store built for search and scale from day one. 🏷️ Title: Index / Document-oriented data store 🔗 URL: 📘 Overview An index is the fundamental unit of storage in Elasticsearch and the level at which you interact with your data. Data is stored one record at a time as JSON "documents," and each document is a set of field key-value pairs plus system metadata such as `_index`, `_id`, and `_version`. ⚙️ How It Works ・Your actual data lives in the `_source` field, while `_index` (owning index), `_id` (unique ID), and `_version` are system-managed metadata. ・A "mapping" defines each field's type and how it is indexed and queried. You pick types like `text` (for full-text search), `keyword` (exact match and aggregations), `integer`, and `date`. ・Even without an explicit mapping, "dynamic mapping" infers types from the incoming JSON, so you can add new fields later and still index them with no schema migration. ・Internally, an index is split into "shards" distributed across nodes. Data inside a shard is written as immutable "segments," and replica shards provide redundancy and scale. ・Settings like `index.number_of_shards` (fixed at creation), `index.number_of_replicas` (adjustable later), and `index.refresh_interval` (default 1s) control index behavior. 🛠️ Practical Usage Indexing a single document is straightforward. `POST products/_doc/p-1001` `{ "name": "Wireless earbuds", "price": 8900, "stock": 120, "category": "audio" }` For large loads, the `_bulk` API batches many operations in one request. `POST products/_bulk` `{ "index": { "_id": "p-1001" } }` `{ "name": "Wireless earbuds", "price": 8900 }` `{ "index": { "_id": "p-1002" } }` `{ "name": "USB-C cable", "price": 1200 }` Adding a brand-new field later (e.g. `sustainability_score`) just works thanks to dynamic mapping. 💡 Use Cases A classic pattern is modeling an e-commerce product catalog as a `products` index, one product = one JSON document (name, price, stock, category, description). A daily batch loads hundreds of thousands of records via `_bulk`, and you can introduce new attributes without waiting on an RDB schema change. ⚠️ Caveats ・A field's type cannot be changed once set. To change a type you must reindex into a new index. ・Use a regular index for frequently updated documents; use a data stream for append-only time-series data. ・Shard count and size directly affect query speed and cluster stability. Avoid huge numbers of tiny shards and aim for sensible shard sizing. #Elasticsearch# #DataModeling#
Show more
Truly determining AI upper limit is data modeling capability. This insight gives us more confidence in PAN Project's future data infrastructure! New ideas. New connections. Back to accelerate crypto × AI. 🚀 #AI# #Crypto#
Show more
# Neo4j Features and Practical Usage 🎨 The picture of your business that you draw on a whiteboard becomes almost directly the database schema — that is the joy of graph modeling. 🏷️ Title: Graph Modeling Methodology (Whiteboard Model to Physical Model) 🔗 URL: 📘 Overview Graph data modeling is the practice of mapping the "picture" of your business domain step by step into a physical graph model. Neo4j's official guide systematically presents the flow of conceptual model to implementation to refactoring, migration from a relational model, and design options that improve performance. It answers the questions that come up in every design review. ⚙️ How It Works Modeling generally proceeds through these stages: ・Conceptual design: enumerate the entities in the domain and decide the nodes and the relationships (verbs) that connect them ・Implementation: map the whiteboard picture directly onto nodes, labels, types, and properties ・Refactoring: iteratively improve the model to fit your query patterns The biggest decision point is whether to "reify an event as an intermediate node" or use a "direct edge." ・Direct edge (`(:User)-[:ORDERED]->(:Product)`): when the relationship is simple with few attributes ・Intermediate node (`(:User)-[:PLACED]->(:Order)-[:CONTAINS]->(:Product)`): when a single event involves multiple participants, line items, states, or timestamps For naming, use "label = singular noun" and "relationship type = upper snake-case verb" as the baseline. 🛠️ Practical Usage If an order needs quantity, price, and status, reify it as an intermediate node rather than a relationship. ```cypher CREATE (u:User {id: 'u1'})-[:PLACED]->(o:Order {id: 'o1', status: 'shipped', at: datetime()}) CREATE (o)-[li:CONTAINS {qty: 2, price: 9.99}]->(p:Product {sku: 'sku1'}) ``` In fraud detection, turn account, device, phone, and address into nodes and connect shared relationships as edges. ```cypher MATCH (a1:Account)-[:USED]->(d:Device)<-[:USED]-(a2:Account) WHERE a1 <> a2 RETURN a1, a2, d ``` 💡 Use Cases This connects directly to "the business picture is the schema" design: discovering fraud rings via shared devices and addresses, or reifying orders into intermediate nodes in e-commerce to track line items, shipping, and returns. ⚠️ Caveats ・Both "everything as intermediate nodes" and "everything as direct edges" are extremes. Decide by working backward from your query patterns (how you will traverse). ・Refactoring large datasets later is expensive. Anticipate your main queries first and firm up the model. ・Carrying over relational normalization habits and creating too many table-like nodes makes traversals verbose. #Neo4j# #DataModeling#
Show more