Is it possible to insert values in a Database with a
checkbox? Say I have a recordset and if the check box is checked I
want to insert the value of the of the field in the DB.
<%=rsqa.Fields.Item("recini").Value%>
That is a persons initials, i want to insert those initials in a column
if it is checked, if it isnt checked nothing is inserted..
what Im trying to do is to insert into the database the values of the checked checkboxes of the recordset fields the appear in the table I've written the following code:
I have a form that is passing a number to check box values with the same name (productID) but different values (numerical values). It is also passing a warehouseID as a hidden field.
I need to dump these values into an access table called wtbProductWarehouses with fields titled ProductID and WarehouseID. What is the code that I need to write to have it loop through all of the productID values and individually add each one to the db while also adding the warehouseID with it.
I am having problems inserting checkbox data into my database. The string data from the text files in my form have no problems being inserted in the db. Code:
I have a form that if a user selects a certain option from a dropdown list a checkbox will appear. This checkbox references information from another table and then multiplies a figure before it is submitted (well, that's the theory anyway!)
I can't seem to get the multiplier to work. Can someone please give me some advice to this? I've included some simplified code that concentrates on the areas that I'm having difficulty. Code:
A page displays the Product literature that a customer can request to receive by postal mail by clicking a check box. The literature selections are created by a dynamic record set based upon what the company enters into the Literature table (currently 10 selections). The checkbox form tags are:
LiteratureID is the Access autonumber primary key field. I can use the LiteratureName in the "name" attribute if it is easier.
The form processing page needs to Insert each selection into its own record in another table. This "requested" table also inserts the database ID for the customer that is created after first inserting the customer contact info. In other words the "requested" table needs to record the customer autonumbered db ID and each selected checkbox value.
I have an .asp page with a form to copy job responsibilites form one job to another. It is a hotmail type interface with checkboxes besides each responsibility. After submitting, it should copy the selected resp's to a different job. After that it should renumber that job's responsibilities.
This is the code I am using now to copy:
copySQL4 = "INSERT INTO jambue.RESP(POSCODE,IDCODE1,IDCODE2,RESP_NUM,RESP) SELECT '" & id & "' POSCODE,'" & dept & "' IDCODE1,'" & unit & "' IDCODE2, '999' RESP_NUM, RESP FROM jambue.RESP WHERE (POSCODE = '" & POSCODE & "' AND IDCODE1 = '" & sourceDept & "' AND IDCODE2 = '" & sourceUnit & "') AND RESP_NUM IN (" & Request.Form("chk") & ")"
As you can see the value '999' is hardcoded in there as the new Responsibility Number to go with the copied responsibility. I use this because there are no jobs with that many responsibilities. This works fine if I only select one resp. to copy over. But if I select more than one that part still runs fine but I get an error with the below. It says too many rows would be affected. Of course, this must be because there are now at least 2 responsibilites with the same RESP_NUM. Code:
An insert page and an update page will not let checkbox data be posted to the database. I am using Dreamweaver for all code with no tweaking on my part. If i remove all checkboxes from page i can post from both pages.
I've made sure that there is no data type mismatch. I do have another DB table which i can post to without incident. It seems i have exhausted my ability to solve this one.
I've been choosing to insert data ni my db using a recordset with methods AddNew and Update. I would like some advices to make my coding opractice better. For example: am I doing it right? Is there a better to do what I'm doing and so on...:
I have a form form.asp to insert data into the table1 of the db.mdb file. In db.mdb file I have two tables one is table1 and other is table2 now the fields in both table are as
Table1
ID (AutoNumber) Name (Text) Roll No. (Number) Class (Text) Address (Text) Result (Text)
Table2 ID (AutoNumber) Roll No. (Text) Result (Text)
Now I want that whenever that data is posted into table1 then table2 should autoupdate the corresponding data. how this is possible?
i have 2 web pages where in the first page, the user is allowed to make a series of selections from combo boxes (one of which is position eg programmer) and when the user clicks next(next1 button), a 2nd page appears with a table in it in the format below (the user is being rated on the different duties he performs in this page and the duties are retrieved dynamically based on the position the user selected in page 1):
when the user has filled in the scores, he clicks next (next2 function) to save the data in a table in the db. i am able to retrive all data except the duty. can anybody help me out. Code:
I have a form that I created via DW that inserts data into a db. I also have code that I want to use which will email the results of the form. However, I have no idea how to combine the two functions (insert and email) into one page of code. Is there a way to merge the two? Where would I put teh email code? Code:
I'm using conn as ADODB.Connection object. when I write:
conn.execute "insert into table (binarydata) values ('" & binarydatastringvariable & "')" it returns the error:
Unclosed quotation mark before the character string '(here is some string given)'. How can I insert binary data to a ms sql server 2000 table without using adodb.recordset?
I have 6 textboxes where user can input data (or can leave it blank). I need to insert all the data (if not blank) into the database. How should be SQL query be like? ...
I need to know how can i insert the data that is saved in an excel file into my SQL Server database.. I've seen some websites.. but i dun quite understand them. I would be great of you can explain to me the steps in doing tat etc...
I'm using the detailsview to perform edit and insert of new records via an object datasource.
If an error occurs on the insert, I want to preserve the data the operator tried to input, along with my error messages. Currently, it appears that the detailsview is trying to rebind after the error, to the empty/null detail item(on insert it is null), and thus I lose all the operator's input. Can someone suggest the proper way for me to achieve the persistence I'm looking for?
I want to insert the data into the MS Access Database using Visual Basic 6.0. Anybody please heplp me to tell the steps to insert the data into the database.
is there a way of having a dropdownlist and a text field with a checkbox so that you can check a box and have the vaule assigned from a option selct list or check another box and have the value assigned from a textfield?
I would like to make an interaction with a database using ADO and SQL. I would like to display some parts of the database using checkboxes to choose the different parts. But I don't know how to build the SQL command in fuction of which checkbox is checked.
I have a checkbox which is used to determine whether or not the user wants to display a map of their business with their listing the value of which is being written into a database.
When I am outputting the listings I am just trying to use a simple if else statement
i.e. If(ShowMap = true)Then Response.Write("<td>Show Map</td>") Else Response.Write("<td>No Map</td>") End If
Problem is I know the database contains different values for ShowMap i.e. some true, some false. Yet when I use this code, No Map is output for all records.
I have a profile search where people can search through our dating profiles. I want to add a checkbox which when checked filters out those records where the recordfield pictures is empty.
I have problems figuring out what the checked value of the checkbox should be and how to use the information from the checkbox in the searchresults page to build the record set. For understanding, if a user does not have a picture the picture field is empty.