datamodel

Cassandra getting data (query on different attributes)

dear how i can get data from Cassandra using value posts = { '1': { //this post id 'user_id': '4', 'body': 'This is awesome!', }, } i cen get the post using post id can i get posts related to certain user i mean get post related to user_id=4 like an example (query using user_id attribute) regrads ...

This is wrong: a column can references primary keys in different tables depends on value of another column?

One of my colleague designed a table schema, and in one of the tables a column can references primary keys in different tables depends on value of another column. I know it is differently wrong, but can not find theory to support me. His schema like this: table video: (id, name, ...) table audio:(id, name, ...) table review_item( item_t...

App Engine Datastore - Data Model question

I need to design a data model for an Amazon S3-like application. Let's simplify the problem into 3 key concepts - users, buckets and objects. There are many ways to design this model - I'll list two. Three Kinds - User, Bucket and Object. Each Object has a Bucket as its parent. Each Bucket has a User as its parent. User is the root. Dy...

Cassandra/BigTable data model - what's the best approach for building indexes?

I'm in the process of spiking a conversion from MySQL to Cassandra for PenWag.com. In Cassandra, I'm storing Users keyed off of a GUID, but users sign in with their email, not the GUID (obviously). GUID as a key for Users makes sense to me more than email for two reasons. From a practical perspective it seems that it's too cumbersome ...

App Engine - ReferenceProperty and custom indexes

This is a follow-up question to Drew Sears' answer to this discussion: http://stackoverflow.com/questions/3314721/app-engine-datastore-data-model-question If I model bucket as a reference property in the object kind and say I want to query for objects in bucket 1234 with size > 1000. My query will look like "where bucket = key('Bucket'...

Is there a safe subset of JSON that can be used with all JSON parsers & databases

JSON is still becoming more and more important for exchange of data but the JSON specification is rather lax in some aspects: The names within an object SHOULD be unique. An implementation may set limits on the size of texts that it accepts. An implementation may set limits on the maximum depth of nesting. An implementatio...

difference between User and Account object in social network design?

I am building a data model for a social networking site and lost of how to model Users and Accounts. 1) User signsup and creates an Account. So we assign the User a user Id like on most social websites we see which is same profile ID. Now is that the account ID too? OR is there a separate account ID also hidden? If user can have multipl...

REST and JAVA JPA

I am trying to understand the code of some project which is not properly documented.Am the only developer working on the task.I dont have much experience. There is a data model and there are some classes witten to access it.It was mentioned that the data model has some rest api on top of it.But when i see the code i can see getter cod...

ExtGWT- GXT, how can i define a class that extend from BaseModel?

I have read some tutorials, documentations but i don't know how to define a class that extend from BaseModel or ModelData? Specifically, I don't know how to name getter and setter methods and the values inside the method. Are there any code convention? Example: public void setName(String value) { set("name", value); //why is it "n...

Should model objects be flexible

Hello, [Sorry but work is proprietary so I cannot give details of objects] I am working on a Java application with a colleague. I am doing the client side and he is writing the server code. The application displays a table of X objects. The columns of the table show some of X's attributes. In addition we have a column that shows a cou...

CoreData - Data Models

Having created an entity, and run the app successfully, I realised I had missed something out of it. I added the new attribute and now get an error regarding different data models, unable to open, SIGABRT (to paraphrase, but I think you get the picture). How do I go about resetting the data model, or will I have to create a new entity? I...

UML Domain Modeling

What is the difference between Domain Model and data model? ...

Qooxdoo TreeVirtual only returns expanded nodes as dataModel

Hi, when i do a this._tree.getDataModel(); in qooxdoo on a treevirtual, i only get back the expanded nodes. How can i get all nodes in the tree? ...

Model design in ASP.NET MVC

I am constanstly having problems with model design in MVC. Mostly all of my projects require some entities that are to be created, edited and deleted. Most of these entities have some common properties like creation date, modified date, author, modified by and in some cases even more descriptive properties are common. Because of that I h...

Why should primary keys of DB not be shown in html code, e.g. in select fields?

Hi, anywhere I read that values in select boxes (or anything else in the html code) should not be the primary key of the database table. For example: <select> <option value="1">Value 1</option> <option value="2">Value 2</option> </select> In the database there are lookup tables with these values as primary key (1, 2, 3,....

Are many-many relationships to be avoided and if so, what is the alternative?

I was left a comment that many-many associations are to be avoided, but I cannot find the original comment/user who left me this info. So I'm asking the community, are many-many associations to be avoided, if so why, and what is the alternative? example: A restaurant offers many types of burgers which can be dressed with many different...

Is there an Erwin Macro to pull out the table comment/definition?

I created a script template to generate the extendend properties to basically to include the data dictionary in the database, however, i couldn't find any macro to read-out the table comment from the model. Is there any hack for this? ...