similar to: Fast Bulk Inserts?

Displaying 20 results from an estimated 10000 matches similar to: "Fast Bulk Inserts?"

2006 May 09
2
Bulk Inserts. Fast way to insert 1000s records?
Hi, This code loops through my results and saves them : @results.each{|r| r.save} There are potentially thousands of results. This takes ages to complete. Is there a quicker way to do this? Any help is greately appreciated Thanks Chris -- Posted via http://www.ruby-forum.com/.
2005 Mar 10
11
Default Values
Where in the application would you suggest I set default values that are read for every action and in some cases changed and somecases not. Basically on some pages I am getting the <title> from the DB and if not I want to put a default one up. Any suggestions?
2005 Dec 14
3
Plugin w/ Migrations and/or Fixtures?
I''m working on a plugin which needs to add both schema and data to the app database, and I''m trying to figure out the best way to do it. I''d like to use a db migration to modify the schema and load the data from a YAML fixture, but Rails doesn''t seem to support migrations for plugins. To do so, the schema_info table would need to change to include a
2005 Dec 09
6
Which mysql for a new project?
Hi all, I am about to start a new RoR project. Which version of mysql is the current best one to use? I will be using the soon-to-be-released RoR 1.0 for the project. I really don''t want to start a PostreSQL vs. MySQL vs. Whatever war. I have all databases including Oracle at my disposal. This project will be my testbed for using RoR with mysql. I will be doing other tests with other dbs
2006 Feb 16
2
Postgresql array converts to string????
Hi We are using postgresql with rails, we find out that when we read array from postresql (postgresql support array type in table) the rails (or postgresql_adapter) converts the arrays into Strings, example: we have a data type array in a table which has two cells: [cell1,cell2], rails will convert them into string like this {cell1,cell2}. So after received the result from a SQL request we have
2008 Feb 15
17
centralized or decentralized puppet infrastructure
Hi All, In my companies environment, we have multiple sites in multiple geographic locations, sometimes with high latency between the sites. I''m trying to come up with a solution that could provide puppet infrastructure to all sites nodes. ----a few assumptions--- - puppet manifest / configuration is fetched from a centralized version control system. - store db is needed (ssh keys,
2009 Jun 16
2
Statistically detecting thresholds...
Rers: I have some ecological data (stream velocity vs. % cover of submerged weeds) that shows strong evidence of a thresholding step-function, e.g. below some velocity, % cover ranges from 0% to 100% (with no apparent relationship to velocity within this range of velocities), but above a certain "threshold" velocity, the % cover does not appear to exceed, say, 10%. There are good
2006 Feb 26
3
Fast inserts?
There are cases when I have to create the same record 100 times. Is there a faster way than: 100.times{Obj.create(@params[:obj])} ? Bogdan -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060226/75d1e099/attachment.html
2009 May 03
12
DNAT Question
Hi list, I have a shorewall installed on 2 interfaces which also has multiple static public IP. Let''s say I have 1.2.3.4 and 1.2.3.5. I have assigned nat with: 1.2.3.4 eth0 11.22.33.4 no no But then I have a situation where I need 11.22.33.44 to connect to a host in the net zone and appears also to be 1.2.3.5 not only 1.2.3.4. How to do it? TIA Willy
2010 Jan 17
2
For loops in R
Hello. I've just started using R and am trying to figure out if the two codes snippets below have the same output gBest<-floor(runif(popsize,min=1,max=top)) velocity[i,j]<<-.4* velocity[i,j] + 1 * runif(1) * (pbestsVar[i,j] - popVar[i,j]) + 1 * runif(1) * (archiveVar[gBest,j] - popVar[i,j]) and for (i in 1:popsize) { for (j in 1:maxvar) { gBest<-sample(top,size=1)
2006 Jul 03
0
Slow bulk insert query
As part of my application I calculate/generate a fair chunk of data, and I then stick the reults into the database (mysql). This takes the form of a single "INSERT INTO foo(...) VALUES(...) " statement that is approx ~500k The dats itself consists of pairs of integers. If I dump the query string to disk and paste it into the query browser and run it then execution is <1 second. If
2009 Jun 08
2
problem with bulk insert into a *.csv file
Hi all, I am trying to create a "index.csv" with caliculating different types of caliculations . In that i have to caliculate on 10,000 studies and have to insert many no of rows more than 500,000 for that right now I am inserting every row after caliculating and doing data.frame but its taking much time to create that index.csv is there any thing like bulk insert in to file
2005 Jul 29
1
Asterisk 1.0.9 and PostreSQL DB
Hello everybody, now I'm using MySQL for SIP/IAX friends and CDR. Is it also possible to use PostreSQL instead of MySQL? Regards Bastian
2008 Jul 01
2
Graph Order in xyplot
I have constructed a Trellis style xyplot. lengthf <- factor(length) xyplot(SLI$velocity ~ SLI$width | SLI$lengthf, layout = c(2,7), xlab = "Width (cm)", ylab = "Velocity (m/s^2)", col = "black") This produces a lovely little plot. However, the grouping factor(lengthf) isn't in the right order. My values range from 2-28 and the 2 graph on the bottom left and
2009 Jun 17
2
Difference beetwen element in the same column
Hi, i have this file pressure,k,eps,zeta,f,velocity:0,velocity:1,velocity:2,vtkValidPointMask,Point Coordinates:0,Point Coordinates:1,Point Coordinates:2,vtkOriginalIndices 0.150545,0.000575811,0.0231277,0.000339049,-0.0193008,0.00318629,-6.24066e-07,5.39599e-05,^A,7,0,0,0 0.150546,0.000782719,0.0226157,0.000497957,-0.0192084,0.00367781,5.09813e-06,5.90689e-05,^A,7,0.0003035,0.000225,1
2008 Sep 03
23
error connecting to mysql
i was trying to setup an application checked out from svnin my local machine. i managed to do all that is required except when it came to the step of creating databases for the application, when i tried to connect to mysql i got this error ERROR 2002 (HY000): Can''t connect to local MySQL server through socket ''/var/lib/mysql/mysql.sock'' (2) i have spent more than 5
2003 Sep 26
3
Std. errors of intercept and slope
Dear all, I have the following output generated by linear regression. Since there is only one regression intercept and one slope for one set of data, what is the meaning of std. error for intercept and that of slope? Thanks in advance. Sincerely, Minghua > data(thuesen) > attach(thuesen) > lm(short.velocity~blood.glucose) Call: lm(formula = short.velocity ~ blood.glucose)
2011 Mar 18
1
predict lm doubt
Hello, does anyone knows this predict is not resulting? # lm predict dfTestes3sitesCriptic$Velocity_corrected <- ifelse (dfTestes3sitesCriptic$Season == "A" & dfTestes3sitesCriptic$BeforeAfter == "Before", (dfTestes3sitesCriptic$Velocity * mVel3ABefAfter), (ifelse (dfTestes3sitesCriptic$Season == "Sp" & dfTestes3sitesCriptic$BeforeAfter ==
2006 Feb 27
6
MySql 4.0.16 and Migrations
It appears that you cannot use migrations (out of the box) with mysql 4.0.16, because when creating a table, the statement says "ENGINE=InnoDb", instead of "TYPE=InnoDB". Looking at the source code for the adapter, this appears to be hard coded. Is there any supported way to make this work with older versions of MySQL? David
2012 Feb 29
2
function for filtering and deleting vector entries
Dear helpers I have two data sets saved as vectors (temperature and velocity). Now I need to "take out" a span of temperature and its corresponding velocity in the other vector. How can I achieve that? I tried to write a function,which takes a vector entry and then decides wether to delete the temperature entry or not and simultaneously doing so with same entry in the velocity