|
Ton9
Starting Member
14 Posts |
Posted - 2001-04-24 : 01:28:41
|
| I have a DB that has a field called propertyID that is declared as an int and is the identity seed all of my other fields are a varchar. Ok I have a file that calls a function, UpdateListing, that I included here:UpdateListing propertyID, city, bedrooms, bathrooms, garagesize, typeofprop, intsize, hasView, waterfront, acres The UpdateListing code looks like this:Sub UpdateListing(propertyID, city, bedrooms, bathrooms, garagesize, typeofprop, intsize, hasView, waterfront, acres)Dim SQL 'Listing_update is a Stored Proc -- StrFix is a function that puts the string in the appropriate formatSQL = "Listing_update "&propertyID&", "&StrFix(city)&", "&StrFix(bedrooms)&", "&StrFix(bathrooms)&", "&StrFix(garagesize)&", "&StrFix(typeofprop)&", "&StrFix(intsize)&" , "&StrFix(hasView)&", "&StrFix(waterfront)&", "&StrFix(acres)'Response.Write(SQL)ConnOpen ''Function call to open DBConn.Execute(SQL)Conn.CloseEnd Subthen the Stored Proc Listing_Update is as follows:CREATE Procedure Listing_update( @propertyid int, @city varchar (50) , @bedrooms varchar (8) , @bathrooms varchar (8) , @garagesize varchar (8) , @typeofprop varchar (8) , @intsize varchar (8) , @waterfront varchar (10) , @hasView varchar (10) , @acres varchar)AsUPDATE RealEstateList Set propertyID = @propertyid, city = @city, bedrooms= @bedrooms, bathrooms=@bathrooms, garagesize = @garagesize, typeofprop = @typeofprop, intsize = @intsize ,hasView=@hasView, waterfront =@waterfront , acres=@acresWHERE propertyID = @propertyidreturnOk the problem is that in the stored proc I am having a problem with declaring propertyid as, @propertyid int. When I do this I get the following error: Error 206 Operand type clash int is incompatible with UniqueidentifierIf anyone sees something wrong in my code I would appreciate some advice.Thanks in Advance!!Edited by - ton9 on 04/24/2001 01:36:47Edited by - ton9 on 04/24/2001 01:42:41Edited by - ton9 on 04/24/2001 01:45:22Edited by - ton9 on 04/24/2001 01:56:18Edited by - ton9 on 04/24/2001 01:59:30Edited by - ton9 on 04/24/2001 02:00:22 |
|