i have a website going .. .. ofcourse you use the Ws-FTP to upload the
photos to the page .. and i have to use SQL program to insert the file
names and values into the Database ..
i have been doing this for the longest time .. ill show u an
example below ..
Insert INTO PHoto (FOLDER, PIC_NAME, TAKEN_FROM, TAKEN_DATE, MONTH_YEAR,
DISPLAY_FOLDER, MONTH_YEAR_ID) VALUES('PHOTO BLAH BLAH BLAH .. ..
basically all the values .. the name and dates etc.
been doin it for the longest time .. excute the line and it will give me
an OK .. and my photo will be up on the website! ..
i tried uploading some files today .. and i get this weird message!
[microsoft][ODBC SQL server Driver][Sql server]String or binary data
would be truncated.
and now i can't put anythin into the database cause everytime i try to
excute and put those files up .. it gives me that error!
can anyone help plz?
--
Posted via http://dbforums.comArabian143 (dani@.windsorsocial.com) writes:
> Insert INTO PHoto (FOLDER, PIC_NAME, TAKEN_FROM, TAKEN_DATE, MONTH_YEAR,
> DISPLAY_FOLDER, MONTH_YEAR_ID) VALUES('PHOTO BLAH BLAH BLAH .. ..
> basically all the values .. the name and dates etc.
>...
> [microsoft][ODBC SQL server Driver][Sql server]String or binary data
> would be truncated.
This means that some of the values you are trying to insert is longer
than the column has foom for. For instance, assume that FOLDER is
char(20), but you try to insert 'C:\some-folder\some-sub-folder\files'
which is more than 20 chars.
If you don't care about truncation, include the statement SET ANSI_WARNINGS
OFF, and SQL will truncate in silence and not raise an error.
--
Erland Sommarskog, SQL Server MVP, sommar@.algonet.se
Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techin.../2000/books.asp|||thanx alot for responding ..
do i set the line next to the lines that im executing .. or beside them
.. or do i just execute the ANSI_warning thing by it self ..
when do i use this command and how many times do i have to use it!
thanx ..
im sorry im kind of new to this so i need exact details
This means that some of the values you are trying to insert is longer
than the column has foom for. For instance, assume that FOLDER is
char(20), but you try to insert 'C:\some-folder\some-sub-folder\files'
which is more than 20 chars.
If you don't care about truncation, include the statement SET
ANSI_WARNINGS
OFF, and SQL will truncate in silence and not raise an error.
--
Erland Sommarskog, SQL Server MVP, sommar@.algonet.se
--
Posted via http://dbforums.com|||hi again ..
i tried that line..
is said ok ..after i executed it ..
but i still got the same error after i tried to send a file to
the database!
im so lost man!
HELP!!!!!!!!!!!!!!!
This means that some of the values you are trying to insert is longer
than the column has foom for. For instance, assume that FOLDER is
char(20), but you try to insert 'C:\some-folder\some-sub-folder\files'
which is more than 20 chars.
If you don't care about truncation, include the statement SET
ANSI_WARNINGS
OFF, and SQL will truncate in silence and not raise an error.
--
Erland Sommarskog, SQL Server MVP, sommar@.algonet.se
--
Posted via http://dbforums.com|||nevermind i got it working
thing had too many god damn values
it was a big value .. but i had to narrow it down
but u gave me the idea and i thank u ..
bye for now
--
Posted via http://dbforums.com
No comments:
Post a Comment