Correction:

Yes, mysql throws these errors. In other dbs, they just trucate and insert, but mysql always throws an error, so you have to be careful.

Should be:

Yes MSSQL throws these errors, in other dbs, like mysql the data is just truncated and inserted. MSSQL will throw an error on any data larger than the field it is going into.

--

Robert Garcia
President - BigHead Technology
VP Application Development - eventpix.com
13653 West Park Dr
Magalia, Ca 95954
ph: 530.645.4040 x222 fax: 530.645.4040
[EMAIL PROTECTED] - [EMAIL PROTECTED]
http://bighead.net/ - http://eventpix.com/

On Dec 2, 2006, at 2:06 PM, Robert Garcia wrote:

Yes, mysql throws these errors. In other dbs, they just trucate and insert, but mysql always throws an error, so you have to be careful.

But even if witango thinks it is varbin(0), it would work if the field could hold the amount you are inserting. It sounds like the field is not set right from a sql design side. You should set as a varbinary(largestsizepossible) like 16000 or whatever. Or just use an image field, or binary.

Yes, you should just be able to throw the arg in there, if you are using a witango insert/update action, but not with direct dbms.



--

Robert Garcia
President - BigHead Technology
VP Application Development - eventpix.com
13653 West Park Dr
Magalia, Ca 95954
ph: 530.645.4040 x222 fax: 530.645.4040
[EMAIL PROTECTED] - [EMAIL PROTECTED]
http://bighead.net/ - http://eventpix.com/

On Dec 2, 2006, at 10:30 AM, Jason Pamental wrote:

Thanks Robert - I'm wondering if there is some sort of issue with the varbinary(max) datatype in SQL Server 2005. That's supposed to allow the largest files to be inserted, but in the dev studio it shows as varbin(0). I'll have to try some different datatypes - but is that the right approach - take the postarg containing the file and insert it via an insert action, no conversion or anything?

Cheers,

Jason

-----

Jason Pamental
Director of Web Services
North Sails

Office: 401.643.1415
Fax: 401.643.1420
Mobile: 401.743.4406
Email: [EMAIL PROTECTED]




On Dec 2, 2006, at 1:15 PM, Robert Garcia wrote:

I am not familiar with SQL Server 2005, but I know 2000 will throw errors like that when the length of what you are inserting is greater than the field length you are inserting into.

Either, change the length of the field in the table schema, or use <@left > to limit the <@arg> on the insert to make sure it is not more than the length of the table field.

--

Robert Garcia
President - BigHead Technology
VP Application Development - eventpix.com
13653 West Park Dr
Magalia, Ca 95954
ph: 530.645.4040 x222 fax: 530.645.4040
[EMAIL PROTECTED] - [EMAIL PROTECTED]
http://bighead.net/ - http://eventpix.com/

On Dec 2, 2006, at 9:35 AM, Jason Pamental wrote:

Hi all-

I've read through lots of posts about inserting BLOBs, but am hitting snags trying it out for the first time.

I'd like to use the varbinary(max) data type in SQL Server 2005 so I can create a full-text index on the files in the system, but when I try to insert the file (an @arg from a form) I get an error (String truncation right). Am I missing a step - do I need to do a conversion on the postarg to binary prior to insert?

Any ideas would be most welcome. My goal is to convert from a filesystem based storage method for an intranet to a DB-based one.

Thanks-

Jason

-----

Jason Pamental
Director of Web Services
North Sails

Office: 401.643.1415
Fax: 401.643.1420
Mobile: 401.743.4406
Email: [EMAIL PROTECTED]




___________________________________________________________________ _____
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

____________________________________________________________________ ____
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

_____________________________________________________________________ ___
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

______________________________________________________________________ __
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf


________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

Reply via email to