title: creating a copy button using sql apex oracle
body: <p>I wanted to create a copy button in a form but this button needs to work using an sql statement which will be like</p>
  
  <p><code>select name, address1, address2, zipcode, car_type, model from Users WHERE report_id=:report_id</code></p>
  
  <p>I will explain more into this with an example.</p>
  
  <p>If on a report I have a list of users and when you click on one of the user, it will take you to a form. In this form you can exit and <code>save</code> it, where the <code>save button</code> is, they will be another button called <code>copy</code>, this button will use the <code>sql</code> above and will copy <code>SOME</code> information on the form based on the <code>report_id</code>(the current report being viewed/edit in the form.)</p>
  
  <p>The <code>copy button</code> will redirect to a form page and will render the information it goes from that sql statement.</p>
  
  <p>I want to use sql statement because in</p>
  
  <p><code>action when button clicked</code></p>
  
  <p><code>with these values</code> it says that colons, commas show not be in those values for example address_1, car_type, and other datatype contents those and because of this, I do want to do it this way. I did try it but I kept getting a <code>404 error page</code> thats why I want to try the sql way.</p>
  
  <p>How will I be able to do it this way please?</p>
  
  <p>EDITTED TO ADD IMAGE FOR MY IDEA IN WHICH I THINK MIGHT SOLVE THIS PROBLEM
  <img src="https://i.stack.imgur.com/2NYB3.png" alt="enter image description here"></p>
  
  <p>the image ABOVE shows my <code>COPY</code> button. as you can see I item and values is the <code>order_id</code>
  <img src="https://i.stack.imgur.com/6vnPH.png" alt="enter image description here"></p>
  
  <p>The image above shows the <code>PROCESSES</code> in which the sql query is run and <code>condition</code> it is the copy <code>button</code>. </p>
  
  <p>The way i think this will work is that when you click on the copy button, the sql query will run and use the current <code>order_id</code> on the <code>form</code> to get all the information in the sql and show it on the form field.</p>
  
  <p><img src="https://i.stack.imgur.com/8jrRG.png" alt="enter image description here"></p>