similar to: sql server freetds/odbc question

Displaying 20 results from an estimated 100 matches similar to: "sql server freetds/odbc question"

2006 Jan 10
1
sql server & linux: left join problem
I''ve got a left join problem of some sort connecting from linux FreeTDS/ODBC to SQL Server. It''s similar to the false post I had earlier, but this is a real problem. Here''s my code: def find_recipes_for_workorder @recipe_pages, @recipes = paginate_with_sort :recipes, :per_page => 10, \ :joins => ''left join workorder on
2006 May 15
1
Ajax Scaffold is htmlescaping "&" in url''s
Seems like I have a problem with html escaping of "&" in my url''s. "Create New" have following link: http://localhost:3000/stylesheets/new?scaffold_id=stylesheet&page=1&sort_direction=asc Any ideas how I can fix this? Using: ajax_scaffold_generator (3.1.2) & rails (1.1.2) Regards Henrik
2006 May 18
3
Model Madness: habtm vs through
This has me scratching my head: a Person has many Things a Person has many Collections a Collection has many Things ...Things in a Collection are ordered ...Things in a Collection can be related to (created by) any User ...a collection has additional attributes, such as a name etc I am confused about habtm in rails (especially when using acts_as_habtm_list) vs. going the :through route.
2013 Apr 03
2
strange behavior with active relation any? method
In console, I run the following and any? returns true: drivers = Driver.select("drivers.*, drivers.id").joins([:reports, :driving_habits]).where("extract(MONTH FROM reports.time) = ? AND extract(YEAR FROM reports.time) = ?", 3, 2013).uniq.order("drivers.id asc").page(2).per(1) drivers.any? => true This correctly evaluates to true because the relation contains one
2012 Mar 06
0
Devise/Cancan Signout User On Controller Action
I have implemented Devise for Authentication and Authorization in ROR application everything seems fine but getting one issue. I have two modals "Account" and "Transactiona" , and so two controllers respectively. My Transaction Index view call one of Account Controller method like this
2005 Nov 03
9
[Idea] session-wide persistent variables
I was thinking about having instance variable stored and fetched from session container automatically before calling an action and after the action is finished. Using methodology of accessors it would look like: class MyController < ActionController::Base persistent_attr :person def alfa person = ''John Smith'' # render as usual view alfa.rhtml with anchor
2007 Oct 15
6
SQL injection with :order, :limit, :group
I know how to avoid SQL injection attacks when you use :conditions User.find :first, :conditions => ["login=?", params[:username]] but how about with :order, :limit or :group? # uh-oh...spaghetti-oh User.find :first, :order => "login; delete from users; select * from users" Pat --~--~---------~--~----~------------~-------~--~----~ You received this message because you
2006 Mar 18
2
redirect killing dispatch.cgi
hi, having a maddening problem with a redirects between controllers. app is working fine on my two local machines, a mac and a pc, with either webrick and lighttpd/cgi on either machines. i move it to my hosting provider and try to get it working with apache + cgi, most of it works, but it fails at a specific spot, and causes dispatch.cgi to hang indefinitely. nothing shows up at all in the
2005 Sep 18
5
NameError: uninitialized constant Addres
I created some scaffolding for an Address model and an Addresses controller. When running the functional tests for the addresses controller, I get this exception: "NameError: uninitialized constant Addres" The exception seems to start from this function: def list @address_pages, @addresses = paginate :address, :per_page => 10 end I''m guessing pluralization bug?
2006 Jan 04
2
Updating Attributes in a HABTM Join Table
Is there a way to update attributes in a HABTM join table? Right now I am deleting the join and then recreating it with new attributes. I have a table "categories" and another table "items". They are both HABTM with the join table "categories_items" between them. If an item is joined to a category once, no problem, we create the join. But if an item is
2006 Jan 02
6
Paginate with joins messing with id
Hi all, Best wishes for the new year! :'') I''m very new to Ruby and Rails, and I ran into a problem with the "paginate" function. When I use the following method to get a number of forum topics based on a category name passed via the URI: @topic_pages, @topics = paginate :topics, :joins => "INNER JOIN categories ON
2006 Apr 09
4
Inheritance via Though Associations?
I posted something about this a week ago wihtout response, but have made some progress since. However, I''m still not getting exactly what I want. OK, three core tables: create_table :reference_items do |t| t.column :title, :string, :limit => 255 t.column :year, :integer, :limit => 4 t.column :type, :string t.column
2006 Feb 16
1
Pagination help/how to
Hello, I want to know how can I paginate a set of records. It seems there is no direct way of doing this, and I am not able to understand the documentation of paginate, so any pointers on how to do this will be much appreciated. To be specific what I want is that the records returned by user.recipes, the recipes of the particular user be paginated. My attempt to do this failed because
2006 Jul 13
0
AR Sybase adapter with FreeTDS
Hi there ! After writing up a little adapter to access my sybase server, using odbc/dbi/freetds/unixodbc (yes all of these), it''s now time to have a *real* adapter, not running through to-many-to-count layers. I plan to use the FreeTDS library rather than Sybase because of the availability of FreeTDS for windows os. Is there already a work in progress for this kind of stuff ? Are
2006 Mar 09
0
Sybase/FreeTDS and RoR
Hi there ! I''m drilling for some framework/apserver solution and come to RoR. After using InstantRails, I would try to run it on my test platform (Solarix 10 x86 on 1 machine, Sybase ASE on another, FreeTDS for the join). I could not manage to have the sybase driver for ruby compile with FreeTDS. So I try to run a ODBC bridge. All seems good (freeTDS runnin, unixODBC working with
2010 Oct 22
1
MS-SQL / Freetds -- func_odbc
Hi folks, How would I go about running a stored procedure call from asterisk via func_odbc. I'm after an example entry in func_odbc if possible for ast 1.4 Also, if someone could post an insert statement that actually works, would be nice. Thanks, :)
2005 Dec 05
0
about php-ODBC , unixODBC, freetds and MSSQL server
maybe someone here can help me understand why I am getting this strange behaivor. I am connecting to a MS SQL server from PHP by the ODBC module, I use unixODBC-2.2.9-1, freetds-0.63-1.2.el4.rf and php-4.3.9-3.9 all but the freetds package came with CentOS-4.2 + updates the problem is that I am getting -1 from the odbc_num_rows(); function, I search the net and it looks that this is a very
2005 Jun 16
2
Error when compiling in freeTDS support
I'm trying to use freetds/odbc to write CDR records to a MSSQL database but when I installed them and tried to compile asterisk again I get: _tds.c cdr_tds.c: In function `mssql_connect': cdr_tds.c:415: `TDSCONNECTINFO' undeclared (first use in this function) cdr_tds.c:415: (Each undeclared identifier is reported only once cdr_tds.c:415: for each function it appears in.)
2005 Sep 29
0
please help on FreeTDS (writing CDR to MS-SQL or MySQL)
Hi, I'm trying to install FreeTDS. I followed the instructions on http://www.voip-info.org/tiki-index.php?page=FreeTDS, but still can't get it to work. I serched around trying to find instructions on it, and it seems the same info (even wording) appear on all sites I found. I downloaded freetds-0.63, and followed the instructions step by step, and when I try to re-compile Asterisk (#make
2006 Nov 07
0
Asterisk and FreeTDS 0.64 or >0.63
Hello all, just curious if anyone's successfully compiled (*) with the latest FreeTDS code/driver. The Makefile in (*) seems to only take care of 0.63 or older. I tried to muck around with it a bit into tricking to compile for not just 0.63 but anything later than 0.62 but it seems to crap out complaining about CDR modules, which I really don't need. It's been a while since I tried it