search for: name_id

Displaying 9 results from an estimated 9 matches for "name_id".

Did you mean: name_in
2011 Jul 11
36
has_many and belongs_to association
Hi , I want to test the one below but I got the problem belongs_to :name, :class_name => "Phrase", :foreign_key => "name" in my test context "test"do should have_many :phrases end in language.rb belongs_to :name, :class_name => "Phrase", :foreign_key => "name" error is 1) Failure: test: check has_many and belongs_to
2008 Sep 28
2
passing variable between methods
How can I pass @member varible from def member to def name and insert it into name_id? These methods are in the same controller. def member @member = params[:member] || '''' member = @member end def name name_id = @member end -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message becau...
2006 Mar 23
4
belongs_to more than one model
Suppose I have one table: states id statename And I have two other tables that contains states: houses id color state_id places id place_name state_id How would my model relationships look like? class State < ActiveRecord::Base belongs_to house belongs_to place end class House < ActiveRecord::Base has_one state end class Place <
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 Jul 26
4
Dropdown with concatenated columns.
What is the best way to create a drop down where the viewable text in a concatenation of 2 or more columns? For instance, I hane a lookup table with these columns. Model FOO columns: id , name, phone In my drop select tag, I''d like the user to see: "name1 phone1" "name2 phone2" etc.. I know I can do this using find_by_sql . .. But, isn''t there a more
2006 Mar 02
5
Two foreign keys on the same column?
Let''s say I have three hypothetical MySQL tables: ? people, with columns id, gender, and source_id belongs_to :boys and :girls ? boys, with columns id and name has_many :people ? girls, with columns id and name has_many :people The gender column in people specifies which of the two source tables the source_id refers to. For example, if we have values: 1, boy, 1 in people,
2005 Jun 29
3
Setting the value of a primary key field
...lue to alpha3t, it doesn''t end up in the insert statements. The unit test tells me: ActiveRecord::StatementInvalid: ERROR: null value in column "alpha3t" violates not-null constraint : INSERT INTO i18n.iso639_eng ("name", "alpha2", "alpha3b", "name_id") VALUES(''G angsta'', ''ho'', ''dog'', NULL) I totally agree! I don''t want any NULL values in my alpha3t column, so is Active Record simply ignoring this field because it thinks it should leave primary keys alone or something? Or does...
2014 Apr 01
2
imap process and indexer-worker crash while creating folders
...tadata = {guid = '\000' , virtual_size = 0, cache_fields = 0x0, precache_fields = (unknown: 0), backend_ns_prefix = 0x0, backend_ns_type = (unknown: 0)} #18 node_add_to_index (seq_r=0x7fffe1eb2330, node=0xb22780, ctx=0xb34ef0) at mailbox-list-index-sync.c:45 _data_stack_cur_id = 6 irec = {name_id = 65, parent_uid = 0, guid = '\000' , uid_validity = 0} seq = 11759984 #19 mailbox_list_index_node_add (seq_r=0x7fffe1eb2330, name=, parent=, ctx=0xb34ef0) at mailbox-list-index-sync.c:87 node = 0xb22780 dup_name = 0xb227b0 "GoogleMail 01.04.2014 19:58" #20 mailbox_list_index_s...
2013 Apr 09
1
2.2.0rc6: crash with mailbox_list_index=yes (and virtual?)
..._fields = 0, backend_ns_prefix = 0x0, backend_ns_type = 0} #30 node_add_to_index (ctx=0x15d6fa0, name=<value optimized out>, node_r=<value optimized out>, created_r=<value optimized out>) at mailbox-list-index-sync.c:45 _data_stack_cur_id = 6 irec = {name_id = 1, parent_uid = 0, guid = '\000' <repeats 15 times>, uid_validity = 0} seq = 8767310 #31 mailbox_list_index_node_add (ctx=0x15d6fa0, name=<value optimized out>, node_r=<value optimized out>, created_r=<value optimized out>) at mailbox-list-index-sync.c:...