Retrieving Array From Single Column In Database

I have about 26 checkboxes that place all of my contacts into categories so in my database for contacts i have a field called categories that contains all of the categeories that each contact belongs to seperated by a ",". 1,5,17 etc.

I need help getting these values out of the database so that when I user select category 17 they get all of the contacts that containg the 17 in their respective categories field.

View Replies


ADVERTISEMENT

ASP Output Is Double Line Spacing And Single Column

I have a prebuild freeware script that is installed and working fine. I am not a programmer by any means, but can usually hack through it and figure out how to make the changes needed. I just can't seem to get this one figured out.

The output is double line spacing and only a single column. Can someone help me to make the changes required to have it just one breakrow (no line spacing), and if possible, to have 2 or three columns? Code:

View Replies View Related

Retrieving Multiple 'values' In A Single OPTION ITEM

I have a difficult technical challenge I'm facing. I need to retrieve multiple values for the very bottom item in the list, 'Federated' (ignore the rest).

The database will query based off the option 'value', however, in this special case I want to perform a retrieval based off of multiple of values. I want to try to use the existing code without reinventing the wheel. Code:

View Replies View Related

Single Record In Array Produces Error.

I get a "Either BOF or EOF is True, or the current record has been deleted. Requested operation requires a current record.

/tourasp/town.asp, line 200 "

error when running following piece of code:

set RS = Conn.Execute(strSQL)
DS = RS.GetRows()' -- (this is line 200)
RS.close
Conn.close
set RS = nothing
set Conn = nothing

If the recordset has two or more records in it, it works fine, but if the recordset has only record in it, I get the error. Code:

View Replies View Related

Query Database, Column 'ID'

The following code works fine doing a query in the db and return the data with the link ...mes.asp?month=X (where X is a month and mes.asp is the name of the file that this code is in...)

I have a ID column in the database and would like to know how to catch data from ID.. i have tried without success, dunno why but the code comes with a error in the line "rs.Open sqlStr, data_source"... Code:

View Replies View Related

Database Column Search

I am looking for a asp script, that will do an OR search on keywords in two differant columns in an MySQL database. for example if someone searches for joe bloggs I want to bring back all records that have either of the words joe or bloggs in column one or column two.

I have found a script that does exactly what I want but it will only search one column of a database whereas i would want it to search two columns. http://www.4guysfromrolla.com/webtech/052799-1.shtml

how to modify this code or point me in the direction of some other code that will do the same job.

View Replies View Related

Displaying A Database One Column At A Time

I know how to write a script that will show all the tables fieldnames and then all the tables fields, but how can I do it so that it shows the database table one column at a time? for instance:

fieldname 1
<br>
1st fieldvalue for this column
2nd fieldvalue for this column
3rd fieldvalue for this column
<P>
fieldname 2
1st fieldvalue for this column
2nd fieldvalue for this column
3rd fieldvalue for this column
etc..

View Replies View Related

Password Protecting Single Pages In Access Database Cms System

I am working on a CMS website which uses a access database.

When a user adds a page a record is added to a table in the database. The user choses the page style from a selection of 7 or 8 layouts.

I have been asked to find out if I can password protect one of those pages??

I have tried a few sites but not found much. The it has been done before is to add a password protected layout and build a login area into the site.

The effect i want is for the user to click the page and a username and password box will apear?

View Replies View Related

Retrieving Data Strings From Database

I am submitting data to a database field, and the data is being submitted in the following manner to a table in the database:

5,3,4,4,3,3,4,5,4,5,5

It's all comma delimeted. Now, what I would like to do is have an update page in which a user can update these values. I am trying to place the values in a repeated text box that corresponds with a repeated question.

The questions that I am displaying are in a repeated field and each question has a text box that will hold the value that corresponds to. I would like to be able to bring in each value into a repeated text box. Right now, each repeated text box contains the above information. (5,3,4,4,3,3,4,5,4,5,5). Is this possible?

View Replies View Related

Retrieving Database Fields Problem

I'm trying to retrieve information from a field in a database, which contains data, some of which are the same. ex:

let's say the table is called "Person_info" and there are 5 rows of info with a different person's info.

let's say i want to display the info in the fields called "City" but there are duplicates ex:

Toronto
Vancouver
Toronto
New York
Atlanta

I'd like it to display all the cities in there on a web page, but, I don't want it to display the same city twice:

so it'll display this:

Toronto
Vancouver
New York
Atlanta

I just can't get it to work? it keeps displaying duplicates.

View Replies View Related

Problem Retrieving Data From Database

I have a search set up on my site to compare between two <select> values and the value in the data base, but not sure if I have the sql statment correct, my search returns all rows from the table, I want specific row that is between one form select and another... ie. below

for this particular example I want to know if the database AD_PRICE field is between <select name=price> and <select name=price1> and if so, return the only those rows, currently all rows are being returned... Code:

View Replies View Related

Retrieving Infornation From An Access Database

I am trying to write a web application that can retrieve information from an access database, store it in a recordset, update it, then update the access database. However, when I try to update the recordset, I get an error (500).

I have checked my field names a million times (so I am pretty sure it isn't a spelling mistake or anything like that), but nothing is working. I included my code so you can take a look at it. Code:

View Replies View Related

Retrieving Data From Access Database

does any one just help me with the an example of retrieving data from access data base?

View Replies View Related

Retrieving Limited Words From Database

Just wondering. I am developing a blog. I would like to display the message post on the blog to be limited to, say, 100 words rather than the whole message itself as this will increase the page length.

I would like to know if there is a method to count the words from the record in database and display only 100 hundred words from the actual message..

View Replies View Related

Retrieving BLOB Fields From A Database?

I am currently working on a document management system for my company's Marketing department. They wish to be able to upload files to the server.

Rather than deal with the many permissions issues we have had in the past with saving and deleting these files to the server's file system, this time we are trying to use SQL server BLOB fields to store the files.

The premise is simple -- a user clicks on the link and the file is then shown in the browser. The documents are mostly word, Quark, and Adobe Illustrator documents. I was thinking the code would go something like this: Code:

View Replies View Related

IIS Running - Error Retrieving Database

I have sucessfully installed IIS 5.1 on XP Pro, and have validated a couple of test .asp pages.

When I try to connect to Access through Front Page, i get the following error:

The Database Results component on this page is unable to display database content. The page must have a filename ending in '.asp', and the web must be hosted on a server that supports Active Server Pages.

View Replies View Related

Apostrophe Error While Retrieving The Record From The Database

I am using a Replace function to replace single quotes with double when
submitting a text field in the database i.e. Replace (q, "'", "' ' ")
which works fine. When I retrieve the field from the database which has
apostrophe I am getting 'Object expected' error message. Is there a
way to fix this?

View Replies View Related

Retrieving Data From Database - Query String?

I have this page with photo thumbnails that are clickable. Each photo has corresponding info saved on a database. When the thumbnail is click, im trying to show the data in an asp page called info.asp.

sample:
Photo #1 when clicked goes to: info.asp?no=1
Photo #2 when clicked goes to: info.asp?no=2
so on so forth..

the database fields are:
no
picname
date
details

I only know how to display ALL info from a database.

But i cant figure out how to display SPECIFIC info triggered by a query string. Example. Photo #1 is clicked. I only want the data that corresponds to Photo 1 to be displayed. How can i do this?

View Replies View Related

Retrieving Foldername And Filename Place Into Database

I want to seach though the drives i.e c or d drives and find for the folders and subfolders and even the files and by that order only it should be inserted into the database.I am using MSACCESS database.

View Replies View Related

Retrieving Information From Database Using Multiple Search Criteria

I am trying to search for clients contained within a database using multiple search criteria that the user is able to select using a front end form.

The user is able to select there criteria by selecting one or more check boxes and the results are thus retrieved based on what the user has selected. The search works fine until you try and select multiple client types Code:

View Replies View Related

Database Into An Array

I have a database of Company titles that I want to grab from an access
database, put into an asp array and then pass it to javascript so I can
output it into a CSS styled javascript menu. Right now I am stuck on
how to exactly put the database entries into an asp array. Below is
what I have so far.

So I want it to return distinct entries from the
Title field and put it into the array called Titles after the asp code
has done an HTMLEncode to make sure I can also pass it along to another
asp page. Basically I need to know what to put after the Do While NOT
Rs.EOF. Code:

View Replies View Related

Form Into Array & Database.

What I need to do is to create a form of a dynamic size, and then save
everything from the form in a database. The number of forms depends on
a number from the database which I know how to get. I need to have a
comment and a number, for example if the number from queried from the
database is 2, then I need 2 forms, and it would be something like so:

Comment: Something
Number: 4

Comment: SomethingElse
Number: 6

When the user clicks the submit button, this would be saved in a
database in a table, in a new row. I have the database created and
inserting works very good when inserting just one row, but I need to
insert more then one row at a time, so it would be something like
this: Code:

View Replies View Related

Searching Database Using An Array

I have the following code and nee to know how to make it return all records where sha is equal to any of the values in the array I have defined. Code:

View Replies View Related

Populate Array From Database

I need to populate an array with two columns of data from a database eg Firstname and second name and sorte alphabetically. So both of these columns go in to one array, I found this code.

View Replies View Related

Array/database Compare To Determine...

...selected value of select box.

...a select box.

I have a static array with 10 elements in it. I am trying to create an update form for a mysql database.

I want to get the info from the database to populate the field of the update form. My select box is populated by the array and I want the value that is stored in the database to be the "selected" element in the select box(= to array element). I hope this is making sense. Code:

View Replies View Related

Problem With Adding Array To Database Table

I have an array which I want to save into a database table I tried a few things but it doesn't work. This is as far as I got: Code:

View Replies View Related

Writing Array Of Random Numbers To A Database

I am trying to write an array of random numbers to a database. The array part is working fine, but when I go to update the dataabse, it inserts the last value of the array into all the fields in the database .....

Dim MyValue,sqlRandom
Dim arrayRandom(8)
for i = 1 to 8
Randomize
MyValue = Int((100 * Rnd) + 1)
arrayRandom(i) = MyValue
response.write "<p> Array Value:" & arrayRandom(i)

sqlRandom = "UPDATE CarParkDetails SET FreeSpaces = '" & arrayRandom(i) & "'"
Conn.execute(sqlRandom)

next

I can't see whats wrong!

View Replies View Related

Varying Number Of Database Columns Into Array

I have a DB that contains several columns named Line1, Line2, Line3, and Line4. After that I there are 50 columns named Data0 through Data49. Data0 and Data1 will always contain text but Data2 through Data49 may or may not be empty.

I am trying to take the values out of the database and put them into arrays. Since Line1 through Line4 never change I have no problem getting them into one array but I am lost on the logic/syntax on how to not only determine how many Data(n) cells are populated but then how to get them into a new array.

View Replies View Related

Matching Array Index To Values Retrieved From Database

I have this dynamic array(shown below) that I need to match to values (1 - 10) that I am returning from the database via DSN connection object.

The values I need to match are on the same page (in their own table) but I am not sure how to match up the array indexes to these values. I want to be able to display the array result as part of or nested in another table. Code:

View Replies View Related

How To Make Column Of Table 1 = To Column Of Table 2?

I want MS Access 2000 database column of table 1 = column of table 2. This is what I was doing: Code:

View Replies View Related

Rebuilding Of An Array From An Existing Array

I dump the entire recordset into an array:

If not rs.EOF Then
aEmp = rs.GetRows()

Contents of the array are in this order:

EmpID,EmpName,Indent,Sub_ID,Lft,Rgt,MgrID, LastName

This query sort on the basis of Lft and Rgt columns.

The name of the array is: aEmp.

My question here is how can I get only the LastName from the aEmp array into another array so that I can sort the names alphabetically and then display the employees in the alphabetical order.

Or is there is another way I could this by using the same array while keeping the lft and rgt sort of the query? If I sort based at the SQL query level, I can see the names sorted by the lft, rgt and lastname, but since the lastname is at the end of the sort list - it does not appear alphabetically.

View Replies View Related

Array Integers Vs Array Variables

In working with arrays, I have found that I am unable to dimension and array
with a variable that has an integer value but I can redimension one this
way. I haven't see any information that tells me if this is a requirement,
although it appears to be because I get an error if I try it.

Ex.

Dim b
b = 10
Dim a(b) ' this errors out but
Dim a() ' this
Redim a(b) ' works

Code:

View Replies View Related

Single Value

I have been using recordsets to access data from a database.I then loop thru each row in a dataset and assign the values to the objects on my web page.The particular sql stmt that I have right now, only returns a single value from a database. I need to assign this single value to a variable in my asp code. Can I do this without using a recordset?

If I have to use a recordset, do I just do var1 = recordset("columnname") (I ofcource create the connection object, the sql stmt and stuff first).

View Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved