Re: Sql Server Error When Loading Fixtures

Brian Takita
Mon, 24 Oct 2005 19:13:17 -0000

I think found the error.
I to make my id column a varchar that was set based on the web_site_id and
account_id columns. My intention was to create a readable id column.

Am I correct in saying that Rails only allows an integer for the id column?

I think will refactor my design to have one table per website type, which
would remove the need for the web_site_id column, allowing me to make the
account_id the pk.

On 10/24/05, Brian Takita
<brian.takita-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:
>
> Hello,
>
> I get the following error when loading some Fixtures into the Test
> Database for a unit test.
> I''m using the Sql Server adapter.
>
> It seems like a AR is trying to call another query in the transaction
> without closing the first RecordSet. Has anybody had this issue and have a
> workaround?
>
> ActiveRecord::StatementInvalid: Execute
> OLE error code:80004005 in Microsoft OLE DB Provider for SQL Server
> Cannot create new connection because in manual or distributed transaction
> mode.
> HRESULT error code:0x80020009
> Exception occurred.: SELECT @@IDENTITY AS Ident: INSERT INTO
> web_site_logins ([web_site_id], [account_id], [password], [login]) VALUES
> (''nanet'', ''2'',
''2nanet_password'', ''2nanet_id'')
>
> See
http://support.microsoft.com/default.aspx?scid=http://support.microsoft.com:80/support/kb/articles/q272/3/58.asp&NoWebContent=1
>
>
>
> --
> Thank you,
> Brian Takita
> http://freeopinion.org




--
Brian Takita
http://freeopinion.org


_______________________________________________
Rails mailing list
Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org