RE: [WebDNA] Upload file to mysql

This WebDNA talk-list message is from

2017


It keeps the original formatting.
numero = 113476
interpreted = N
texte = 1071 This is a multipart message in MIME format. ------=_NextPart_000_01A1_01D2A1B6.A906CA40 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Hi Stewart, I have my content field set to MEDIUMBLOB which allows for 16mb max files. So far, I am using files around 100kb, so I am not reaching the max yet. My query writes all the data fields and uploads .txt files, but once I change to a file like a PDF, it chokes. [showif [referer]^file_manager.dna] [FormVariables] [showif [name]^filename] [text show=F]TheFileNM=[Middle StartAfter=filename="&EndBefore="][name][/middle][/text] [/showif] [showif [name]^CPK] [text show=F]CPK=[value][/text] [/showif] [showif [name]^JPK] [text show=F]JPK=[value][/text] [/showif] [/FormVariables] [hideif [TheFileNM]=] [hideif [CPK]=] [hideif [JPK]=] [FormVariables] [showif [name]^"thefile"] [SQLExecute conn_ref=TheBlueBiller&result_var=UPLOAD_INS] INSERT INTO UPLOAD (FILE_ID, COMPANY_ID, CLIENT_ID, JOB_ID, NAME, CONTENT, ROW_ADDED_DTTM) VALUES ('', '[LOGIN_COMPANY_ID]', '[CPK]', '[JPK]', '[TheFileNM]', '[convertchars db=databases/upload.db][value][/convertchars]', '[date %Y-%m-%d %H:%M:%S]') [/SQLExecute] [/showif] [/FormVariables] [/hideif] [/hideif] [/hideif] [!]========UPLOAD.DB FILE------------[/!] FROM TO ' \' " \" \ \\ % \% From: Stuart Tremain [mailto:webdna@idfk.com.au] Sent: Monday, March 20, 2017 6:43 PM To: WebDNA Talk List Subject: Re: [WebDNA] Upload file to mysql Hi Brian I have not done that, but providing your MySQL field is LONGBLOB all should work. Also to be able to insert images that are bigger than 1MB you have to increase the max_allowed_packed option in the server configuration file. I use Navicat to write all my queries and then copy & paset the query into my WebDNA doc. Navicat makes writing & debugging fast. Kind regards Stuart Tremain Pharoah Lane Software AUSTRALIA webdna@idfk.com.au On 21 Mar 2017, at 07:55, Brian Boegershausen > wrote: Anyone successfully upload a file to a mysql db? I can upload a text file but that is it. Jpg and gif fail. Unbuntu 14 Webdna 8.2 Mysql 5.5 Brian Boegershausen --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us Virus-free. www.avg.com --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us ------=_NextPart_000_01A1_01D2A1B6.A906CA40 Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

Hi = Stewart,

I have my = content field set to MEDIUMBLOB which allows for 16mb max = files.

So far, I am = using files around 100kb, so I am not reaching the max = yet.

 

My query = writes all the data fields and uploads .txt files, but once I change to = a file like a PDF, it chokes.

 

[showif = [referer]^file_manager.dna]

[FormVariable= s]

[showif = [name]^filename]

  &= nbsp;           &n= bsp; [text show=3DF]TheFileNM=3D[Middle = StartAfter=3Dfilename=3D"&EndBefore=3D"][name][/middle][/te= xt]

[/showif]

[showif = [name]^CPK]

  &= nbsp;           &n= bsp; [text show=3DF]CPK=3D[value][/text]

[/showif]

[showif = [name]^JPK]

  &= nbsp;           &n= bsp; [text show=3DF]JPK=3D[value][/text]

[/showif]

[/FormVariabl= es]

 

[hideif = [TheFileNM]=3D]

[hideif = [CPK]=3D]

[hideif = [JPK]=3D]

[FormVariable= s]

[showif = [name]^"thefile"]

[SQLExecute = conn_ref=3DTheBlueBiller&result_var=3DUPLOAD_INS]

INSERT INTO = UPLOAD

(FILE_ID, = COMPANY_ID, CLIENT_ID, JOB_ID, NAME, CONTENT, = ROW_ADDED_DTTM)

VALUES ('', = '[LOGIN_COMPANY_ID]', '[CPK]', '[JPK]', '[TheFileNM]', '[convertchars = db=3Ddatabases/upload.db][value][/convertchars]', '[date %Y-%m-%d = %H:%M:%S]')

[/SQLExecute]=

[/showif]

[/FormVariabl= es]

[/hideif]

[/hideif]

[/hideif]

 

[!]=3D=3D=3D=3D= =3D=3D=3D=3DUPLOAD.DB FILE------------[/!]

FROM &nb= sp; TO

'  =              = \'

" &= nbsp;            = \"

\  =             = \\

%  =           = \%

 

From:<= /b> = Stuart Tremain [mailto:webdna@idfk.com.au]
Sent: Monday, = March 20, 2017 6:43 PM
To: WebDNA Talk List = <talk@webdna.us>
Subject: Re: [WebDNA] Upload file to = mysql

 

Hi = Brian

 

I = have not done that, but providing your MySQL field is LONGBLOB all = should work. 

 

Also to be able to insert images that are bigger than = 1MB you have to increase the max_allowed_packed option in the server = configuration file.

 

I = use Navicat to write all my queries and then copy & paset the query = into my WebDNA doc. Navicat makes writing & debugging = fast.

 

Kind = regards

 

Stuart = Tremain

Pharoah Lane = Software

AUSTRALIA

 

 

 

 

 

On 21 Mar 2017, at 07:55, Brian Boegershausen <brian@endeavotech.com> = wrote:

 

Anyone = successfully upload a file to a mysql db?
I can upload a text file = but that is it.
Jpg and gif fail.

Unbuntu = 14
Webdna 8.2
Mysql 5.5

 

Brian = Boegershausen

 

 

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/= list/talk@webdna.us Bug Reporting: support@webdna.us

 

 

V= irus-free. www.avg.com =

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/= list/talk@webdna.us Bug Reporting: support@webdna.us

--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us ------=_NextPart_000_01A1_01D2A1B6.A906CA40-- . Associated Messages, from the most recent to the oldest:

    
  1. Re: [WebDNA] Upload file to mysql (Brian Boegershausen 2017)
  2. Re: [WebDNA] Upload file to mysql (Stuart Tremain 2017)
  3. Re: [WebDNA] Upload file to mysql (Brian Boegershausen 2017)
  4. Re: [WebDNA] Upload file to mysql (Stuart Tremain 2017)
  5. Re: [WebDNA] Upload file to mysql (Stuart Tremain 2017)
  6. Re: [WebDNA] Upload file to mysql (Brian Boegershausen 2017)
  7. Re: [WebDNA] Upload file to mysql (Stuart Tremain 2017)
  8. RE: [WebDNA] Upload file to mysql ( 2017)
  9. Re: [WebDNA] Upload file to mysql (Stuart Tremain 2017)
  10. RE: [WebDNA] Upload file to mysql ( 2017)
  11. Re: [WebDNA] Upload file to mysql (Stuart Tremain 2017)
  12. Re: [WebDNA] Upload file to mysql (Brian Boegershausen 2017)
  13. Re: [WebDNA] Upload file to mysql (Stuart Tremain 2017)
  14. RE: [WebDNA] Upload file to mysql ( 2017)
  15. [BULK] Re: [WebDNA] Upload file to mysql ("WJ Starck, DDS" 2017)
  16. Re: [WebDNA] Upload file to mysql (Stuart Tremain 2017)
1071 This is a multipart message in MIME format. ------=_NextPart_000_01A1_01D2A1B6.A906CA40 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Hi Stewart, I have my content field set to MEDIUMBLOB which allows for 16mb max files. So far, I am using files around 100kb, so I am not reaching the max yet. My query writes all the data fields and uploads .txt files, but once I change to a file like a PDF, it chokes. [showif [referer]^file_manager.dna] [formvariables] [showif [name]^filename] [text show=F]TheFileNM=[Middle StartAfter=filename="&EndBefore="][name][/middle][/text] [/showif] [showif [name]^CPK] [text show=F]CPK=[value][/text] [/showif] [showif [name]^JPK] [text show=F]JPK=[value][/text] [/showif] [/FormVariables] [hideif [TheFileNM]=] [hideif [CPK]=] [hideif [JPK]=] [formvariables] [showif [name]^"thefile"] [SQLExecute conn_ref=TheBlueBiller&result_var=UPLOAD_INS] INSERT INTO UPLOAD (FILE_ID, COMPANY_ID, CLIENT_ID, JOB_ID, NAME, CONTENT, ROW_ADDED_DTTM) VALUES ('', '[LOGIN_COMPANY_ID]', '[CPK]', '[JPK]', '[TheFileNM]', '[convertchars db=databases/upload.db][value][/convertchars]', '[date %Y-%m-%d %H:%M:%S]') [/SQLExecute] [/showif] [/FormVariables] [/hideif] [/hideif] [/hideif] [!]========UPLOAD.DB FILE------------[/!] FROM TO ' \' " \" \ \\ % \% From: Stuart Tremain [mailto:webdna@idfk.com.au] Sent: Monday, March 20, 2017 6:43 PM To: WebDNA Talk List Subject: Re: [WebDNA] Upload file to mysql Hi Brian I have not done that, but providing your MySQL field is LONGBLOB all should work. Also to be able to insert images that are bigger than 1MB you have to increase the max_allowed_packed option in the server configuration file. I use Navicat to write all my queries and then copy & paset the query into my WebDNA doc. Navicat makes writing & debugging fast. Kind regards Stuart Tremain Pharoah Lane Software AUSTRALIA webdna@idfk.com.au On 21 Mar 2017, at 07:55, Brian Boegershausen > wrote: Anyone successfully upload a file to a mysql db? I can upload a text file but that is it. Jpg and gif fail. Unbuntu 14 Webdna 8.2 Mysql 5.5 Brian Boegershausen --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us Virus-free. www.avg.com --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us ------=_NextPart_000_01A1_01D2A1B6.A906CA40 Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

Hi = Stewart,

I have my = content field set to MEDIUMBLOB which allows for 16mb max = files.

So far, I am = using files around 100kb, so I am not reaching the max = yet.

 

My query = writes all the data fields and uploads .txt files, but once I change to = a file like a PDF, it chokes.

 

[showif = [referer]^file_manager.dna]

[FormVariable= s]

[showif = [name]^filename]

  &= nbsp;           &n= bsp; [text show=3DF]TheFileNM=3D[Middle = StartAfter=3Dfilename=3D"&EndBefore=3D"][name][/middle][/te= xt]

[/showif]

[showif = [name]^CPK]

  &= nbsp;           &n= bsp; [text show=3DF]CPK=3D[value][/text]

[/showif]

[showif = [name]^JPK]

  &= nbsp;           &n= bsp; [text show=3DF]JPK=3D[value][/text]

[/showif]

[/FormVariabl= es]

 

[hideif = [TheFileNM]=3D]

[hideif = [CPK]=3D]

[hideif = [JPK]=3D]

[FormVariable= s]

[showif = [name]^"thefile"]

[SQLExecute = conn_ref=3DTheBlueBiller&result_var=3DUPLOAD_INS]

INSERT INTO = UPLOAD

(FILE_ID, = COMPANY_ID, CLIENT_ID, JOB_ID, NAME, CONTENT, = ROW_ADDED_DTTM)

VALUES ('', = '[LOGIN_COMPANY_ID]', '[CPK]', '[JPK]', '[TheFileNM]', '[convertchars = db=3Ddatabases/upload.db][value][/convertchars]', '[date %Y-%m-%d = %H:%M:%S]')

[/SQLExecute]=

[/showif]

[/FormVariabl= es]

[/hideif]

[/hideif]

[/hideif]

 

[!]=3D=3D=3D=3D= =3D=3D=3D=3DUPLOAD.DB FILE------------[/!]

FROM &nb= sp; TO

'  =              = \'

" &= nbsp;            = \"

\  =             = \\

%  =           = \%

 

From:<= /b> = Stuart Tremain [mailto:webdna@idfk.com.au]
Sent: Monday, = March 20, 2017 6:43 PM
To: WebDNA Talk List = <talk@webdna.us>
Subject: Re: [WebDNA] Upload file to = mysql

 

Hi = Brian

 

I = have not done that, but providing your MySQL field is LONGBLOB all = should work. 

 

Also to be able to insert images that are bigger than = 1MB you have to increase the max_allowed_packed option in the server = configuration file.

 

I = use Navicat to write all my queries and then copy & paset the query = into my WebDNA doc. Navicat makes writing & debugging = fast.

 

Kind = regards

 

Stuart = Tremain

Pharoah Lane = Software

AUSTRALIA

 

 

 

 

 

On 21 Mar 2017, at 07:55, Brian Boegershausen <brian@endeavotech.com> = wrote:

 

Anyone = successfully upload a file to a mysql db?
I can upload a text file = but that is it.
Jpg and gif fail.

Unbuntu = 14
Webdna 8.2
Mysql 5.5

 

Brian = Boegershausen

 

 

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/= list/talk@webdna.us Bug Reporting: support@webdna.us

 

 

V= irus-free. www.avg.com =

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/= list/talk@webdna.us Bug Reporting: support@webdna.us

--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us ------=_NextPart_000_01A1_01D2A1B6.A906CA40-- .

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

A *secret* new webdna tag !!! (1999) More on the email templates (1997) Capturing the referring site (1999) More on the email templates (1997) Simple way to create unique SKU (1997) limitation found on group searching (1997) SQL (2003) FYI: Error message (1996) Calculating multiple shipping... (1997) Help formatting search results w/ table (1997) value in forms (2000) Enterprise Server (1998) (1998) truncating email part II (1997) Shipping charges depending on tax rate? (1997) Date or time comparisons have bugs ... (1998) Parameter Passing (2000) Forms Search Questions (1997) WebCat hosting providers? (1997) Faxing orders in place of email (1997)