subsonic 3.0.0.3 for multiple primary keys table - subsonic

When I use ActiveRecord template,that can't generator correct primary key for multiple primary keys table.
I can't update that table.

If you mean that your table has Composite Primary Keys (comprised of more than one field in that table), then SubSonic doesn't support it - see Update a primary key value using SubSonic 2.2

Related

can we create datasync between two tables without indexes in azure data sync

can we sync two tables of two different databases in azure without indexes. As, we all know ,if two databases has to be in sync hub database and member data base should have same schema. But is there chance of avoiding indexes.
please help me with this
Each table needs to have a primary key and you cannot avoid that. Please read the following excerpt from Microsoft documentation:
Each table must have a primary key. Don't change the value of the
primary key in any row. If you have to change a primary key value,
delete the row and recreate it with the new primary key value.
Source here.

Inverted index: Delete then Insert pattern?

I have an inverted index table on a table of Users. The table allows querying users by last name. It is called "users_by_lastname".
Primary key of this table has "lastname" in it, so it cannot be updated.
If a user changes their last name in the main "Users" table, should I be deleting and re-inserting into the inverted index table, "users_by_last name"?
I cannot update a primary key column in Cassandra... Are there other patterns that handle this better?
In Cassandra 3.0 you can deal with this problem by creating the inverted index table as a materialized view of the Users table. Then Cassandra will take care of maintaining the view automatically whenever you update the base table.
On earlier versions of Cassandra your only option would be to do a delete and then insert with the new last name in the application maintained inverted index table.

CQL Select on column value

I am creating account data in Cassandra. Accounts are most commonly queried based on an account id. However, often the account is queried by a login name. I have created a user table with primary keys (account_id and login_name). Because of this, I have to "ALLOW FILTERING" on the table to query by the login_name.
Is there a better way to create the table that does not have the impact of a filterable table?
A possible approach is to define a new table that has the exact same elements in the primary key but in the reverse order: (login_name, account_id). You can still keep the table you present as the reference table, which stores all the relevant account data, but this new table would allow you more optimized queries based on login_name. I am not sure how much you would win compared with the query "allowing filtering"... But this kind of "data duplication" for query optimization is a normal procedure in NoSQL DBs.
HTH.

How to create a unique property in Azure Table Storage

In azure table storage is it possible to add a unique constraint on a column of a given table?
Azure Table Storage entities don't have columns. Each entity may have properties and these properties don't need to be the same for each entity.
The only unique constraint is the combination of partition key + row key.
There's an excellent article on Azure table storage here:
http://msdn.microsoft.com/en-us/library/windowsazure/dd179338.aspx
Since it only has a Row Key and a Partition Key, and the Row Key is essentially the primary key, it doesn't look like there's any other constraint you can put on it unless you build that sort of thing into your client/server which uses or exposes it.
From the article:
The Table service does not enforce any schema for tables, so two entities in the same table may have different sets of properties. Developers may choose to enforce a schema on the client side. A table may contain any number of entities.
HTH :)

How to retrieve from two tables with same foreign key repeated more than once?

How to display the data of tables that are linked by a primary key and foreign key where the foreign key of the data repeats?
For ex. I have two tables, ParentTable and Childtable.
The primary key of ParentTable acts as the foreign key of ChildTable.
There are more than one record with same ParentId in ChildTable. How to retrieve them and display in a single Grid or List or any type of view?
As for the query: if you are using Oracle you may use a CONNECT BY statement in your query; otherwise you can just use a JOIN on the foreign key to retrieve the list of couples Parent-Child and handle them in your C# business logic.
As for the presentation: this is the classic tree structure, so you may find a Treeview useful.

Resources