similar to: Better rails way to join tables?

Displaying 20 results from an estimated 3000 matches similar to: "Better rails way to join tables?"

2008 Jan 03
1
Thread_pool bug?
I have a previous question regarding long tasks and the thread_pool (sorry for the dup, I didn''t see the first go through). To try and track things down, I made a change based on a suggestion found in the archives. I moved my import contacts worker to its own file and set the pool_size to 1. class ImportContactsWorker < BackgrounDRb::MetaWorker set_worker_name
2007 Aug 22
3
tackle memory insufficiency for large dataset using save() & load()??
Hello List, i have been agonizing over this for days, any reply would be greatly appreciated! Situation:___________________________________ My original dataset is a .csv dataset (w/ 2M records) with 4 variables: job_id (Primary key, won't be used for analysis, just used for join tables), sector_id (categorical variable, for 19 industry sectors), sqft (con't variable for square
2006 Jul 02
18
JOIN conditions
Hi, how can I get Rails to generate SQL queries with conditions in the JOIN clause? What I would want is: SELECT * FROM people p LEFT OUTER JOIN jobs j (p.job_id = j.id AND j.salary > 9999999) I tried People.find(:all, :include => ''jobs'', :conditions => ''jobs.salary > 9999999'') but that generates SELECT * FROM people p LEFT OUTER
2007 Apr 26
1
mapping column names in legacy schemata
I have a legacy MySQL database with a weird naming convention - all table and column names have a prefix ''_'' , which is annoying, and some of the column names are misnomers. I would like to apply a pre-defined mapping between MySQL column names and method names to be used in the Ruby class, without having the original column names being visible anymore. how can I pre-define a
2008 Jan 03
1
Memory leak and long process problem
I use backgroundrb for many long tasks in my system, but I''m having issues with one in particular. Two large tasks for me are importing people and updating companies. def import_contacts(args = nil) thread_pool.defer(args) do |job_id| begin job = ImportJob.find(job_id) job.process_job rescue => err logger.error "MscWorker#import_contacts
2006 Aug 24
3
A new QueueWorker class
Hello all, I''ve come up w/ a worker class that manages queued jobs using a fixed number of child workers. Well, that''s not quite true -- a new worker is spawned for each job, but you set the total number that may exist at once. There are three components: 1) queue_worker.rb: The singleton worker that manages the child workers. You probably want to auto start this. Make sure you
2005 Dec 05
1
Lack of 'LEFT JOIN' in Oracle 8, any patch for theta style (+)
Dears, Oracle 8 don''t support ANSI syntax with : SELECT e.emp_id, e.fname, e.lname, j.jobdesc FROM employe e LEFT JOIN jobs j ON e.job_id = j.job_id but only SELECT e.emp_id, e.fname, e.lname, j.jobdesc FROM employe e, jobs j WHERE j.job_id (+) = e.job_id JOIN syntax came with 9i. Anyone patched Rails
2005 Nov 20
1
mySQL 5.0 upgrade - incompatible DateTime format?
I''ve upgraded to mySQL 5.0, and it''s gone pretty smoothly except that on DateTime.now doesn''t seem to return a value that mySQL likes any more, as seen in the following exception: Incorrect datetime value: ''2005-11-20T15:33:12-0800'' for column ''logged_at'' at row 1: UPDATE notes SET `due_on` = ''2005-11-20'',
2003 Jan 20
2
Location of fileinfo
hello there, I just started using ogg files. And want to thank you all for this new format. I have written an addon for mirc (chatclient for irc chat networks) to play and exchange soundfiles and I am almost done with implementing the ogg vorbis format into this application. The mirc-scriptinglanguage provides me a command to read a specified number of bytes starting at a specified location of
2005 Dec 12
2
count sql failing with unknown table....
Hey Rails People, I''m doing my first Rails app and I''m having a newbie problem with the count method.... Mysql::Error: #42S02Unknown table ''jobs_sectors'' in where clause: SELECT COUNT(*) FROM jobs WHERE (jobs_sectors.sector_id = 1 ) Extracted source (around line #4): 1: <div class="sectors"> 2: <ul> 3: <% for sector in @sectors
2006 Feb 17
2
Question about policies [OT?]
Hi, I'm using samba 3 as a domain controller. For some XP-pro laptops I would like to disable the firewall when they are logged in on our network (I don't like it but I have to). Is this possible with Windows policies ? If so, does someone know about good reading material about policies ? I do have "Mastering Windows XP professional" but that's absolutely no help. Thanks
2003 Apr 16
6
Slow connection
Hi, Last week I discovered that my samba-server seems rather slow. When I searched around I discovered that I wasn't the only one experiencing this, but I didn't find a solution. I experimented a little, and I hope someone can suggest a solution. First my server : SuSE 8.1, with Samba 2.2.5 (comes with the distribution). From a WinME-client I uploaded a 160Mb file to the samba-server.
2010 Feb 19
2
Client behaviour with sieve
Hi, I have a working dovecot imap-server, with sieve. I find it odd that my mail-clients (Thunderbird 2 and 3) don't report anything that's new in the folders. What I mean is this : Postfix get's a mail and hands it over to dovecot's LDA and sieve moves it to a folder. When I log in with Thunderbird, I see new messages in my Inbox. But that message that was moved to a folder is
2006 Jul 06
4
Oracle HR on Rails
Interesting read...apologies if it has been posted already. http://www.oracle.com/technology/pub/articles/saternos-rails.html -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060706/619e650a/attachment.html
2005 Dec 05
1
Two samba's not playing together
Hi, I just tried to migrate my NT-PDC to samba-3.0.20b. Everything worked fine except for a problem with my old file-server running samba-2.2.5 with winbind. I can connect to and use shares on the new PDC and I can manage users and groups. But when I try to connect to the file-server I'm refused access. When I prepared this mail, I remarked that in smb.conf I somehow deleted the
2008 Feb 01
3
Job Queue
After some initial stumblings, I think I''ve got the hang of backgroundrb. It''s great! I''d been thinking for many many months how cool something like this would be! I''m trying to make a "job queue". That is, a pool of worker threads monitor a queue. When a job appears, one of the workers grabs it and executes the task. When complete, the worker
2015 Jun 22
5
pdf-printer
Hi, I recently migrated from samba3 to samba4. On the samba3 server I had a "printer" that converted pcl6 to pdf. I tried to make a similar printer in samba4, but it's not working. Not working means the printed document is nowhere to be found. This is the section in smb.conf : [papyrusPDF] comment = Papyrus-to-PDF printer path = /var/spool/samba # guest ok = Yes
2015 Jun 30
3
pdf-printer
On 30/06/15 10:10, Koenraad Lelong wrote: > Op 30-06-15 om 08:58 schreef Rowland Penny: > >> >> Hi, did you read to the bottom of this wiki page : >> https://wiki.samba.org/index.php/Virtual_PDF_Printer#Setup >> >> By my reading, if you add what it tells you, you should find a new log >> file in '/var/log/samba/Pdfprint.log' >> >>
2013 Jul 18
2
Archiving mail
Hi, I'm going to migrate my company-mailserver to new hardware. I would like to take the opportunity to archive some older mail. But I would like to have it still accessible, would this be possible with dovecot ? I mean, I would like to put that older mail from different users (I got about 50 users) on some read-only media but mount that media in the users mail-dirs. That way I will have
2009 Oct 26
2
Multiple identities
Hi, I recently moved from courier-imap to dovecot, to be able to work with managesieve. I use version 1.2.5, on suse 10.3. I used the script to migrate the courier maildir to dovecot format. It seems to work fine except for one problem : I use a number of aliasses and with Thunderbird I can select which alias (e-mail-address) to use as my identity when sending a mail. I sniffed with wireshark,