Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6832269
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T22:50:18+00:00 2026-05-26T22:50:18+00:00

How can I INSERT and RETRIEVE with SQL language, an HTML document from a

  • 0

How can I INSERT and RETRIEVE with SQL language, an HTML document from a BLOB field into db2 on ibmI ??

I put the testing.html inside fylesystem but I don’t know if this way is correct or if I can also use a file into my local PC.

I tried this code from STRSQL without success:

INSERT INTO LIB/FILE VALUES('','C','000001',BLOBFROMFILE(/PATH/testing.html))

Is it possible to enter an HTML document type or is there another type field to manage it?

After this procedure I need also a SQL string than can read it.

Thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T22:50:19+00:00Added an answer on May 26, 2026 at 10:50 pm
    $data = file_get_contents("/PATH/testing.html");
    $data = mysql_real_escape_string($data);
    $query = "INSERT INTO FILE VALUES('','C','000001','$data')";
    mysql_query($query);
    

    edit:

    linux file system

    lets assume you are working on /var/www/username/public_html/ folder

    when u try /PATH/testing.html

    program looking for /PATH/testing.html

    direct access to root folder probably u dont have that right

    in the other hand when you try PATH/testing.html ( no / at start )

    program look for /var/www/username/public_html/PATH/testing.html

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need to retrieve information from a SQL server and insert into a XML
I need to retrieve data from several rows and then insert the results into
How can I insert an image in MySQL and then retrieve it using PHP?
How i can insert data into more than one table of an Access database
Is there a way that I can insert values into a VB.NET Dictionary when
I'm trying to insert a value from a datetimepicker value to a SQL Server
I need to insert mutiple data in the field and then to retrieve it
I have inserted xml into SQL Server 2005 through rich text field successfully, now
I insert a new object into LINQ-to-SQL DataContext without calling SubmitChanges() yet: MyDataContext db
In Postgres, I can write INSERT .. RETURNING * To retrieve all values that

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.