|
Apr
5 |
|
awarded | Notable Question |
|
Mar
29 |
|
asked | Android - get list of contacts that doesn't have email |
|
Aug
15 |
|
awarded | Enthusiast |
|
Aug
12 |
|
revised |
rails active record has_many custom query fix string's syntax |
|
Aug
12 |
|
comment |
rails active record has_many custom query would it help to store the Relation object? I am not sure myself, but I think that will prevent creating another object right?
|
|
Aug
12 |
|
accepted | rails active record has_many custom query |
|
Aug
12 |
|
comment |
rails active record has_many custom query i prefer to have relation capabilities. |
|
Aug
12 |
|
comment |
rails active record has_many custom query By doing the second approach, should i then remove the has many association? |
|
Aug
12 |
|
asked | rails active record has_many custom query |
|
Aug
7 |
|
awarded | Popular Question |
|
Jul
30 |
|
comment |
database two column logical OR index, or create separate 'index' table uhm btw, is it okay to have a follow up question? let say we have these arrangement so that team_a_id < team_b_id also the direction flag. Then I have another query to get history of team matches. What I have in mind is to run this query: select * from matches where team_a_id = 1 or team_b_id = 1 then I ended up with similar situation as AB or BA. So I am thinking wouldn't it be better to just duplicate every entry of the matches? so I have A,B, host and another record B,A,away. Then for my new case, I can quickly do select * from matches where team_a_id = 1
|
|
Jul
30 |
|
comment |
database two column logical OR index, or create separate 'index' table Why is it that coding these where clause at the end enable me to use only team_a,team_b index? |
|
Jul
30 |
|
comment |
database two column logical OR index, or create separate 'index' table Thank you for the explanation |
|
Jul
30 |
|
accepted | database two column logical OR index, or create separate 'index' table |
|
Jul
29 |
|
asked | database two column logical OR index, or create separate 'index' table |
|
Jul
25 |
|
awarded | Announcer |
|
Jul
17 |
|
asked | omniauth-identity auth_key |
|
May
30 |
|
comment |
Memcache with both rails and php Thank you. It works like you said. the thing is that my php is a legacy code, and I am trying not to change anything there. I was hoping I can work something out from the Rails side. Another issue is that, in PHP code$hello = array('one'=>1,'two'=>2);
self::$memcache->set('hello',$hello,false, false);
$var = self::$memcache->get('hello');die(var_dump($var));code will output codearray(2) { ["one"]=> int(1) ["two"]=> int(2) }code but from the rails side: codeRails.cache.read('hello')code outputs code"a:2:{s:4:\"satu\";i:1;s:3:\"dua\";i:2;}"code. So why PHP do unserialize here?
|
|
May
30 |
|
comment |
Memcache with both rails and php thanks for the explanation. I wish I had set the notification to my email so I can accept your answer right away. |
|
May
30 |
|
accepted | Memcache with both rails and php |