Displaying 3 results from an estimated 3 matches for "sqlstatement".
2006 Jan 17
4
find_by_sql column ordering defect?
...odelInternationalization.find(:all, :conditions =>
"lower(model_name) = ''project'' AND column_visible_on_quick_screenlist =
true",:order => ''orderno ASC'')
for m in @model
if m.modelonly == false
columns << m.column_name
end
end
sqlstatement = "select id, " + columns.join('', '') + " from projects"
@objs = Project.find_by_sql(sqlstatement)
the breakpointer tells me that:
irb(#<ProjectsController:0x2aaaacb3aa80>):001:0> sqlstatement
=> "select name, begin_date, projected_end_date, ac...
2012 Nov 23
3
read.csv.sql() to select from a large csv file
Dear list,
Dear list,
I am using read.csv.sql() from the sqldf package to read
individual-based data from a csv file that is too large for R.
My original file contains a column called “ID” that
identifies the individual. I would like to read in data for only
one individual at a
time, for example "Bobby".
read.csv.sql("filename",sql = 'select * from file where ID =
2004 Nov 02
2
A little more on R, mdbtools and Access databases
..., header=FALSE, footer=FALSE) {
cat(mstatement, "\ngo", file = "tempR.sql")
sqlOptions <- "-p"
if (!header) sqlOptions <- paste(sqlOptions, "H", sep="")
if (!footer) sqlOptions <- paste(sqlOptions, "F", sep="")
sqlStatement <- paste("mdb-sql", sqlOptions)
tmp <- read.table(pipe(paste(sqlStatement, "-i tempR.sql", dbname)), sep="\t")
names(tmp) <- trim(unlist(strsplit(substr(mstatement, 7, regexpr(" [Ff][Rr][Oo][Mm]", mstatement)[1]), ",")))
system("...