Sorting Asc/desc Feature

I'm building my ASP pages using dreamweaver 8 and some code that I learned along the way.

Can anyone tell me how can I sort (or order) the records in a table just by clicking on any of the columns?

View Replies


ADVERTISEMENT

ORDER BY DESC

This code doesnt work when i put the "ORDER BY TotalP DESC" but i need to bring back the most used number which is in a table. when i dont use the "ORDER BY TotalP DESC" i get 3 numbers showing how many times the data in teh database table appears.

Code:

sqlStatment = sqlStatment + ""
sqlStatment = sqlStatment + "Select Count(Page) AS TotalP "
sqlStatment = sqlStatment + "From hitcounter "
sqlStatment = sqlStatment + "Where UserLevel = '"&typee&"' "
sqlStatment = sqlStatment + "Group by [page], [userlevel] "
sqlStatment = sqlStatment + "ORDER BY TotalP DESC"

View Replies View Related

Day() Feature

I'm having a hard time with the Day() function. Basically, it appears
to be picking and choosing which part of a date string it uses to
return the result ... heres some code :

View Replies View Related

New Forum Feature?

I've noticed changes to the forum, for instance... the addition of a "time spent on forums" and user-post "bar" thingiemabob

...And on the front-page I'm presented with a link to "View my warnings"

Which is obsolete, considering that I don't have any warnings (oh, I'm such a little angel!)

Any news or admin care to comment on this?

View Replies View Related

Attachment Feature

Where do you think I can get just this feature alone in ASP?I just need this feature and not this whole forum. Any other similar product I can use or try?

View Replies View Related

Adding Feature

I am very new to ASP and I am trying to add an existing script.I have an open source shopping cart and I want to add real time shipping rates from USPS.

I have a username and password for the USPS server,but I am having trouble figuring out where to place it. Also if someone as a script to send and recieve data from the USPS server that would be great.

View Replies View Related

Search Feature

I need to provide the search feature on the companys web site. I have read one of the threads here that this can be accomplished via Google. I can't locate the thread anymore. Is it possible? could you please point me to the right resources?

View Replies View Related

Login Feature Using MS Access

I have a website which requires login. The login function works fine, but I want to display this message when someone is logged in: "Welcome, Firstname Lastname". Here is the code for login.asp: Code:

View Replies View Related

Log In Feature Using Two Access Tables

I have a login feature but i want to be able to let users from different tables to log in. The data base is Access and the code is from DreamWeaver MX.

The computer recognises that there are two tables. However i get the message:

Microsoft JET Database Engine error '80004005'

The specified field 'userID' could refer to more than one table listed in the FROM clause of your SQL statement.

/members/loginform.asp, line 21

This is the code:

View Replies View Related

Framed Page Feature

i want to have this feature implemented on a framed page: a two paged frame with:

frame (a) containing a textbox and submit button
frame (b) dispays the url entered in the textbox

i have no idea how i'll program the textbox to accepts urls and open the link in the target frame.

View Replies View Related

Calendar Control Feature

I would like to insert a calendar into a webpage that shows the current date and really needs no updating, fro mthis calendar i would like to select a date from it and have that date inserted into a text field, in all there will be 22 text fields (but for now its probably best to concentrate on one).
The reason being i would like to give the user of the website access to change dates in a table in access. The dates can be calculated from the first date entered into the first text field like so:
All dates will be 7 days apart. Ie if the firsat date is 1/7/04 then make the second 8/7/04 and the third 15/7/04 etc 22 times.

View Replies View Related

Simple Search Feature

i have a text field that the user can input a keyword to search on. i want it to search two fields in my database: productName and productDetails. can someone tell me the sql i would have to use? I know it would be a mixture of using the WHERE and LIKE commands.

View Replies View Related

Auto-remove Feature

I have an email program, that I wrote for my newsletter. When I send my emails, I am getting more and more bad emails. Is there a way to have an auto remore feature that will remore the email from my database?

View Replies View Related

User Login Feature

the database works is it checks over a database and verifies the username & pass with code. Then the user enters the site and there's a seperate table to keep a record of when users log in and log out.

Well basically I'd like to know if and how I could apply a filter using asp code? I'd like to filter out everything but <%Session("name")%> (which displays their username) so that user logged in can view their own records.

View Replies View Related

Site Login Feature

I am creating a message board in ASP, and I want to create a login feature where you can view the site without being logged in as a registered user, or you can be logged in and use more features.

What is the best way to go about doing this? Should I use cookies, or should I just try to create a login feature using VBScript and Database values?

View Replies View Related

Upload File Feature

how to provide the feature for ploading files from a website? i want sum people to b able to upload their files to my server from website, and I am going to read these files later on for ifferent application. am using ASP and vbscript for my applications.

View Replies View Related

Adding ASP File-Upload Feature

I was wondering if any one had any advice for adding on an all ASP file-upload feature to a form. To start I only want to upload JPGs to a folder (max 2 per form) and then write the path to these images along with the form information so the images can be displayed later on.

View Replies View Related

Radio Buttons To Add/change/delete Feature

I have a simple add/change/delete feature going on. I have a products table that I'm selling mock products from. I have a column named category, which users either select baseball or basketball from the radio buttons on a form. I can't figure out how to make this work. I'm implying that the code is working, the record is adding to the database, just not the category field, and when I display all the fields out of my database onto a html page the category field is blank. Below is the code I have.

<tr>
<td>Category:</td>
<td>Baseball<input type="radio" name="category" value="baseball">
Basketball<input type="radio" name="category" value="basketball"></td>
</tr>

Then I dim out a strCategory variable and set it equal to the request object "category"

View Replies View Related

How Can I Give A Nice Print Friendly Feature Through IE For My Website Visitors

I just wanted to know if anyone can tell me how can I give my website visitors the feature of "FRIENDLY PRINTING" through IE. Code:

View Replies View Related

Sorting XML

I've had an ASP project dumped on me written in VBScript. I'm actually a
C#/ASP.NET developer and am struggling trying to find a way to sort the
result of a XPath query executed using SelectNodes?

I'd rather not rely on external XSL files if possible.

View Replies View Related

Sorting

I have this database that contains four columns (ID, Name, Qty1, Qty2). I can display the data on an ASP just fine but what I want is to display the data in Ascending order of the total number between Qty1 and Qty2 of each record (Qty1 + Qty2 = QtyTotal). Obviously the total number is not stored somewhere in the database. So how can I accomplish this?

View Replies View Related

Sorting And Paging

I try to find a script in ASP that combines sorting and paging. I already found various scripts that do one or the other but none does it both. I know I should combine them, but it is very difficult at my level of asp knowledge.

View Replies View Related

ASP Sorting Problem

I wanna ask how to do the following sorting function, for example

Name Age
Brian 22
Alice 17
Patrick 21

when click on name, it will sort by
Alice
Brain
Patrick

when click on age, it will sort by
17
21
22

Is it execute the SQL by hyperlink..? Can anyone give me an example?

View Replies View Related

Sorting On Fields ?

I created a script which suppose to sort on 2 fields. Everything works fine with no errors except when I click on the field that suppose to sort the data it does nothing.

This is the code: Created on test table name Reports2 3 fields id, r_date, r_doc_title

Code:

View Replies View Related

Column Sorting

Can someone please explain to me why the hyperlinked column headings will sort in Firefox and IE 7 but not in IE6. Code:

View Replies View Related

Sorting Problem

I have a set of records which are sorted AtoZ in display. Problem comes is like:

A.1
A.10
A.2
A.20
A.3
A.4
A.5
A.6
A.7
A.8
A.9

Actually A.10 is required after A.9 and A.20 after A.19.

I have searched for this, but found that on every page it sorts records like this. Also, I can not sort items based on ID (auto increment) because certain items are added at later time and some first.

View Replies View Related

Array Sorting

I need a array with x numbers (1 to x) mixed. Like this:

Using 4 numbers (1 to 4), i need:

array(1) = 3
array(2) = 2
array(3) = 4
array(4) = 1

This is random. I make this: Code:

View Replies View Related

Database Sorting

I'm programming as ASP site to show the results of dynamically querying a MS Access database and outputting the results in a table. I've got that part to work. But, what I can't get to work is for the header row of the table to be links to sort the data ascending or descending by that particular field. All I can get to work is having a little +/- next to the column header and those sort it, but I can't figure out how to get the headers themselves to do both sorts when clicked.....can anyone out there help??? Thank you in advance!!! Also, if anyone knows about Access 2000, I've never tried doing this in it before, but I need to export one of the field to be links to HTML pages that describe those seminars, has anyone done that? Just figured I'd ask while I'm typing this

View Replies View Related

FileSystemObject - Sorting

Is there any way to sort the files and folders according to different things (i.e. size, date, etc.)? I'm using For...Next loops.

View Replies View Related

Sorting Recordsets

I have never sorted a recordset - using rs.Sort - i have no problem sorting it in SQL.
All the tutorials i get say that i have to use a client cursor location, so this is my code:

View Replies View Related

Recordset Is Not Sorting

I have the following code which connects to an access database table and prints out each record. For some reason, the ASC is not sorting the records for me. Can anyone see the problem? Code:

View Replies View Related

Sorting By Recordsets Value

I have a table that is just dumping an entire database data. I would like to have the values of the columns re-sort the data. Not the column heads for the data displayed under the column head varies.

For example, one column, Components, displays 80 components types and another column, Category, displays 40 categories types. When a visitor clicks on one of the component values, it should then display only that data. I've done this before but, it has been a very long time. I remember creating a link surrounding the recordset in my table but what was written.

View Replies View Related

Record Sorting

I'm trying to display number of records query and the results I'm getting are only for 10 and not the total number of records queried. For example if I query field "CA" and I know California has 12 records it still only gives me 10 records. Attached is the script.

View Replies View Related







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