Combining An AND With An OR

I have this query that isn't working for me. This is a simple phonebook (first name and last name) form. Trying to accept wildcards. Here is the statement as I see it: Code:

Query = "SELECT cn,telephonenumber,mail FROM 'table' WHERE (cn = '" & FName & "' OR cn = '* " & FName & "') AND (cn = '" & LName & "' OR cn = '* " & LName & "')"

But this isn't working. Where am I messing up the syntax?

View Replies


ADVERTISEMENT

Combining 2 Sql Strings

I have 2 SQL strings:

SELECT *
FROM NK_editie " & MM_whereConst & " " & whereClause & "
ORDER BY editie desc

And

SELECT *
FROM NK_editie INNER JOIN NK_edities ON NK_editie.editieid = NK_edities.ID
ORDER BY editie desc

Now I want to combine those 2 to one string.

I have problems to set it up in working order.
My tryout:
SELECT *
FROM NK_editie INNER JOIN NK_edities ON NK_editie.editieid = NK_edities.ID &
" & MM_whereConst & " " & whereClause & "
ORDER BY editie desc

It shows al the records which are joined, only the second string " & MM_whereConst & " " & whereClause & " is not working.

View Replies View Related

Combining Values

I've created a web form with multiple textfields for acquiring somes date of birth (i.e. textbox for DD, textbox for MM, textbox for YYYY), now what I'm trying to do is grab the values from these objects and combine into 1 session variable, which later on is inserted into an ACCESS database.How do I append these values together to be one value in a session variable (i.e 23122004). I have a input mask inside the ACCESS database, so it needs to go in this format. I assume once I have captured these 3 fields, I need to convert them to integer, and then merge?

View Replies View Related

Combining Rows

I have a database used by another application, i want to be able to manipulate the data stored in the database, the problem is that the way the information is stored its awkward(assume this is purposely so), but i cannot change the db structure at all, so heres my problem: Each Person in this database will have multiple comments stored against them:

ID | CommentCode | LineNum | ValueData
1234 COMM1 1 Something about thi
1234 COMM1 2 s person seperated ov
1234 COMM1 3 er multiple lines
1234 COMM2 1 Something else about
1234 COMM2 2 them

What i want to do is circle through the recordset and combine the multiple lines of the same comment, any ideas/examples?

View Replies View Related

Combining Two Sql Queries

I need to take two seperate queries and put them in a single html table, but i want to combine the sets of data 'while selecting them' so i can use the SQL sort by command to arrange the whole table by date..

sorting the two queries independantly then dumping them to the table results in both queries being sorted independantly, ie the most recent entry(by date) of the second set of data ends up in th emiddle of the table.. any ideas?

View Replies View Related

Combining 2 Variables In A ASP Form

It's regarding an ASP FORM for the credit card process:

I'm collecting credit card information on my secured server. When collecting the Month and Year values (for the expiration date of the card) with Select/Option tags, I don't have a way to concatenate them together prior to submitting the form so I can post them in the format the gateway asked me for (e.g. "mmyy" or "mmyyyy")

Do you have a way where I can submitt those variables togehter in such format? Code:

View Replies View Related

Edit Combining Data

I am trying to edit data from this form in ASp/HTML but because both the field that I am editing is in the text box that has the same name, it is combining the data from both the field and updating in the table. Is there a way I can change the name of the text box progammically?

View Replies View Related

Combining Index Server And SQL Server Search Results

I'm just about to start a project that needs to combine the results of a SQL
Server query with the results of an Index Server query. The basic idea is
that the user enters/selects a bunch of search criteria on a form.

Most of
the criteria selected by the user will be used to select records from the
database - standard WHERE clause stuff - but the user can also enter
free-text that should be searched for in associated uploaded documents.

The
documents are sitting in the file-system with file-name pointers only stored
in the database (not the document). Only records where the associated
free-text is found in the documents should be returned. I'm new to Index
Server and am wondering how is this done. Any good references/tutes?

View Replies View Related







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