similar to: Migrations - use them or not?

Displaying 20 results from an estimated 6000 matches similar to: "Migrations - use them or not?"

2005 Jun 27
9
FK constraints overrated?
Hello folks, I use to think that a relational databases without foreign keys constraints enforced strictly by the RDBMS were no good, piece of crap, data junk. However, I''ve also learned the hard way that FKs constraints imposes serious difficulties when moving data around, specially between different DBs, or for loading test data or for upgrading DBs schemas, or for porting DBs
2011 Nov 28
29
Lack of foreign-key constraints support in ActiveRecord
Is there any reason why AR has never supported foreign-key constraints? I can understand the lack of support for triggers and stored procedures since they are highly dependent on the database to create a wrap API around them. But this is not the case for foreign keys. This is specially important for open-source projects like Redmine/Chiliproject and Gitorious where you shouldn''t be
2006 Nov 10
2
Testing with foreign keys
I''m looking for a plugin/whatever for preloading fixtures, to run tests with FKs defined. Specifying load order just doesn''t work for me, I need to purge the test db, load all fixtures, and only then create the FK constraints. Any suggestions? Isak --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups
2006 Jul 23
7
"throwing out the old": does Rails really not support...
Frankly I''m losing tolerance for the MS "stack." And I''m intrigued by Rails. But in my outfit I''m not only the web person, but also the application person and the DBA. So when I read that Rails doesn''t want to handle things like "compound keys" I blew right by those claims, thinking, "no way." But before I go deeper, I
2006 Jul 10
3
Can migrations set up foreign key references?
I use Oracle and i really want to use migrations, but there seems to be no way to setup foreign key constraints. Is this true? If it is then doesn''t that make migrations useles with Oracle? Thanks Chris -- Posted via http://www.ruby-forum.com/.
2006 Jan 18
3
Support for foreign keys in Migrations
Is there any work being done to add support for defining foreign keys in ActiveRecord Migrations? If not is it something that people would find useful or do most people here believe in the "Application Database" style over the "Integration Database" style [1] as defined by Fowler? I''d love to see support for foreign keys in Migrations. For selfish reasons
2006 Feb 13
5
ActiveRecord with Legacy Database
Hiya RoR gurus, I work at a .NET shop, but I enjoy learning Ruby. So, I wanna prototype some of our product''s screens using Rails (and hopefullly AJAX). One thing I''m not sure about, since I''m a Rails noob, is whether ActiveRecord will get along with our database... So I have two questions: * Can I have ActiveRecord get along with our PascalCase naming conventions?
2006 Jan 05
13
Naming convention for foreign keys
Hi, In "Agilge Web Development With Rails" on page 217, an example of foreign keys is shown. I am however unable to find a definition of wheater the naming of the index is significant. On the above mentioned page, this line is shown in the example: constraint fk_items_product foreign key (product_id) references products(id) In "fk_items_product", "items" is
2006 Apr 02
5
adding primary_key to join table using migrations
Hi list, My tag_question_user join table is not currently a full-blown model. It doesn''t have a primary key - just tag_id, question_id, and user_id. I now want to add a primary key to this model (because I want to add a "description" column as well so users can describe the tag. I''m not sure how to add this using migrations. Here is what I have: class AddNotesToTags
2009 Sep 28
5
Multi-databases support
Hi, While I was hacking ovirt-server, I have found that it's currently restricted to Postgres DB. Even if I like postgres for serious work on a server, I really prefer to hack/dev locally on a Sqlite or MySQL DB. I have googled on rails in order to find a good answer for the "foreign key problem" which forces OVirt to stay on pg. I have found a plugin on this particular
2006 Jun 30
4
ActiveRecord Migrations, without autonumbered PK''s
I love using ActiveRecord Migrations to build tables. Sometimes, I don''t want to use autogenerated PK''s - I want to set them automatically (why? I''m importing read only data from a large list of medications, and want to use the PK''s assigned by the medication research company...). Is there anyway to do this using Migrations? I know that I don''t
2006 Aug 16
0
problems using Migrations
Hi All I am trying to figure out if I can use migratons when the following requirements are imposed at the same time. 1. Migrating data from an old schema to a new schema, the difference in the 2 schemas is about 25%, 3 new tables and 4 new columns. 2. Migrating data from Oracle schema to DB2 schema, around 25% difference in 2 schemas as above. 3. Neither old nor the new schema tables have a
2006 Apr 12
11
validate_presence_of not working for me
Hi all, I just begun with RoR and going through the Agile development w Rails depot example ATM. I did everything according to the book (i believe), and after 3 hours of googling, reading docs, making sure i did everything correctly i can not make the validate_presence_of() to work - at least not as it looks in the book. My Product model looks like: class Product < ActiveRecord::Base
2007 Jun 09
7
create 2 fk referencing the same table
Hi everyone! I have a problem with defining 2 fk referencing the same table. I have a Program table and a Team table. The Program should have an away team and a home team fk. From my understanding, "the fk column should be named after the class of the target table, converted to lowercase, with _id appended". But, in my case, I have 2 fk referencing the same table. How can I do this?
2006 Jul 16
4
migrations questions: MySQL -> postgreSQL
I started my app before migrations were a best practice and have been using SQL scripts. Now I''m looking at potentially having to move from using MySQL to postgreSQL to use a particular hosting provider. I understand migrations are the way to go to make this ''easy'' but it also looks like the use of migrations introduces extra work in other areas. I''d really
2006 Jan 06
4
Are migrations executed within a transaction?
Hi all, Can I safely assume that each migration is excuted within a transaction, so that''s it''s safe to have migrations executing failing statements? Thanks, - Rowan -- Morality is usually taught by the immoral.
2006 Jan 21
7
n-way joins
Hi, I''m somewhat of a Rails newbie and am trying to understand how to formulate n-way (3 or 4 way) joins in Rails (where the join tables contain extra data as well.) Let me give you my basic entities: foos id - pk name - unique bars id - pk name - unique bazs id - pk name - unique frozs id - pk name - unique then i have two separate join tables: foos_bars_bazs - 3 way join
2006 May 25
24
Make these a prt of Ruby on Rails!
3 things that should be part of the main Rails tree: http://www.redhillconsulting.com.au/rails_plugins.html Views? -- Posted via http://www.ruby-forum.com/.
2012 Jun 25
2
Fast Kendall's Tau
Hello. Has any further action been taken regarding implementing David Simcha's fast Kendall tau code (now found in the package pcaPP as cor.fk) into R-base? It is literally hundreds of times faster, although I am uncertain as to whether he wrote code for testing the significance of the parameter. The last mention I have seen of this was in 2010
2009 Jun 05
1
problem with using subset from two different tables
Hi all, I am new to R-project my problem is I tried to get subset from two different tables its giving error but if i m tring for geting results from one table its working actually i have to take values from two tables with applying different conditions on two tables like kk- is an object of one table and fk- is an object of another table here i have to get values from these tables like