Re: Complex MySQL Select Statement Help

2013-02-03 Thread hsv
2013/02/02 12:58 -0600, Peter Brawley On 2013-02-01 10:18 PM, h...@tbbs.net wrote: 2013/01/31 22:24 -0600, Peter Brawley Is this what you mean? Select, pricelist If( !IsNull(specialprice) And specialprice unitprice And CurDate() Between startingDate And endingDate, specialprice, unitprice )

Re: Complex MySQL Select Statement Help

2013-02-02 Thread hsv
2013/01/31 22:24 -0600, Peter Brawley Is this what you mean? Select, pricelist If( !IsNull(specialprice) And specialprice unitprice And CurDate() Between startingDate And endingDate, specialprice, unitprice ) as used_price From catalog Where itemid='WB314'; PB Maybe this is gilding the

Re: Complex MySQL Select Statement Help

2013-02-02 Thread Peter Brawley
On 2013-02-01 10:18 PM, h...@tbbs.net wrote: 2013/01/31 22:24 -0600, Peter Brawley Is this what you mean? Select, pricelist If( !IsNull(specialprice) And specialprice unitprice And CurDate() Between startingDate And endingDate, specialprice, unitprice ) as used_price From catalog Where

Complex MySQL Select Statement Help

2013-01-31 Thread Angela Barone
Hello, I'm trying to write a select query that grabs two prices from my db and displays them on a web page. I want it to grab the `listprice`, and either the `unitprice` or the `specialprice` depending on the following criteria: if the `specialprice` is not empty, AND it's less than

Re: Complex MySQL Select Statement Help

2013-01-31 Thread Peter Brawley
On 2013-01-31 8:13 PM, Angela Barone wrote: Hello, I'm trying to write a select query that grabs two prices from my db and displays them on a web page. I want it to grab the `listprice`, and either the `unitprice` or the `specialprice` depending on the following criteria: if the

Re: Select statement help

2008-01-18 Thread Baron Schwartz
Hi, On Jan 18, 2008 2:59 PM, RoryGRen [EMAIL PROTECTED] wrote: Hi all I am quite new to mySQL and have the following question I hope someone can help me with: I have a database table imported directly from MS Access with two of the field names having brackets - F(1) and S(1). I don't want

Select statement help

2008-01-18 Thread RoryGRen
the database needs updating. How can I select these fields from the table? - SELECT F(1), S(1) doesn't work, SELECT F(1) , S(1) doesn't work and neither does SELECT [F(1)], [S(1)] Thanks, in anticipation! Rory -- View this message in context: http://www.nabble.com/Select-statement-help

SELECT statement help

2002-09-21 Thread Des Dougan
I want to extract data into a temporary table such that unique records with the same primary key (in this case an invoice number) are written to one record, with each of the unique fields extracted being written to a separate field in the temporary table record. I have created my temporary

Re: SELECT statement help

2002-09-21 Thread Paul DuBois
At 21:21 -0700 9/21/02, Des Dougan wrote: I want to extract data into a temporary table such that unique records with the same primary key (in this case an invoice number) are written to one record, with each of the unique fields extracted being written to a separate field in the temporary

Select statement help...

2002-01-12 Thread Tom Jones
Hello, I've been trying to figure this out but I feel like I'm just banging my head on the wall. I hope this is the right forum to pose this question. I have a table of flights which has several fields Table: flights Fields: depart, depart_time, arrive, arrive_time, flight_no, flight_group

RE: Select statement help...

2002-01-12 Thread Carsten H. Pedersen
Hello, I've been trying to figure this out but I feel like I'm just banging my head on the wall. That must be quite painful... I hope this is the right forum to pose this question. It's certainly one of the better ones, yes. I have a table of flights which has several fields Table:

Re: Select statement help...

2002-01-12 Thread Neil Zanella
On Sat, 12 Jan 2002, Tom Jones wrote: Table: flights Fields: depart, depart_time, arrive, arrive_time, flight_no, flight_group I'm trying to do a search on depart and arrive and show only the records which have matching flight_group SELECT depart, arrive FROM flights WHERE flight_group

Random Select Statement - help please

2002-01-09 Thread David V. Edelstein
Hi Roger, Thanks for your reply and I apologize for my lack of specificity on my previous email, thanks for your patience :). I have a people object that has 4 entities. name, pword, user_id, picurl This data is stored in the people table. Each user is identified by a unique user_id. I would

RE: Random Select Statement - help please

2002-01-09 Thread Roger Baklund
* David V. Edelstein I would like to create a mySQL query that will find the max user_id, use this value to calculate a random value of the user_id from [1 thru max], then return the entire row for that person(user_id) filled in with that persons(row) four entities, which I can use to

RE: Random Select Statement - help please

2002-01-09 Thread Rick Emery
Easier method: SELECT * FROM people ORDER BY RAND() LIMIT 1; -Original Message- From: David V. Edelstein [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 09, 2002 1:08 PM To: 'Roger Baklund' Cc: '[EMAIL PROTECTED]' Subject: Random Select Statement - help please Hi Roger, Thanks