How Software Gets Done  


(No Login on Secured Page)

Custom Software Buyers
Request new bids
Search Coders
My Account
 
My Buyer 'To Do' List
 
My bid requests
  My escrow account
 
My General Info
Verification
 
Help for Buyers
Articles for Buyers
FAQ for Buyers
Latest News
 

Custom Software Coders

Newest open work
Browse all work
Search all work
My Account
 
My Coder 'To Do' List
 
My bids
 
My General Info
  My credit account
 
Help for Coders
Articles for Coders
FAQ for Coders
Latest News
 

Affiliates

My account
 
My pipeline
 
My credit account
 
Help for Affiliates
Latest News
 
Newest Open Bid Requests.
Email Sender
By swainclubber on May 9
Max Bid: $50


Disk Format Utility
By CFC on May 9
Max Bid: Open to fair suggestions


Java Project along with UML design
By Silver Green on May 9
Max Bid: $20


rtf to html converter
By aramyus on May 9
Max Bid: Open to fair suggestions


A general class to simulate and extend collections
By aramyus on May 9
Max Bid: Open to fair suggestions


affiliate software
By rdlynch on May 9
Max Bid: Open to fair suggestions


Click here to put this ticker on your own site

Open Work Categories.
Database 
(141 open)
   Access 
(63 open)
   MySQL 
(81 open)
   Oracle 
(10 open)
   SQL Server 
(55 open)
   Other DB 
(13 open)
Documentation / Tech Writing 
(31 open)
Data Entry 
(18 open)
Game Development 
(19 open)
Graphics / Art / Music 
(36 open)
   Graphics 
(44 open)
     3d Animation 
(10 open)
   Art (Misc.) 
(15 open)
   Music 
(4 open)
   3d Modeling 
(5 open)
Language Specific 
(102 open)
   ASP 
(73 open)
   C# 
(36 open)
   C++ / C 
(102 open)
   Cocoa / Obj-C 
(1 open)
   Cold Fusion 
(4 open)
   Delphi 
(28 open)
   Java 
(58 open)
   Perl 
(36 open)
   PHP 
(92 open)
   XML/XSL 
(23 open)
   Visual Basic 
(136 open)
   Visual Basic .Net 
(68 open)
   Other 
(46 open)
Misc 
(30 open)
   CAD 
(4 open)
MultiMedia 
(31 open)
Network 
(47 open)
   Network Design 
(10 open)
   Network Implementation 
(16 open)
Platforms 
(60 open)
   Windows 
(162 open)
     MS Exchange 
(3 open)
     MS Office 
(7 open)
     Other 
(7 open)
   Internet Browser 
(42 open)
   Linux 
(50 open)
   UNIX 
(24 open)
   Hand Held/PDA Programming 
(10 open)
Requirements 
(14 open)
Security 
(38 open)
Testing / Quality Assurance 
(18 open)
Web 
(150 open)
   Page Design 
(71 open)
   Flash 
(41 open)
   Web Services 
(75 open)
   Web (Other) 
(78 open)
Training 
(11 open)
   Computer Based 
(15 open)
 
Other
 
Other Sites

Download the free Rent A Coder IE toolbar!
 
Show Bid Request

SQL Query design
Bid Request Id: 37145
Bookmark in my 'To Do' list
Posted by: kdundon (2 ratings)
(Software buyer rating 10)
Non-action Ratio: Very Good - 0.00%
Posted: Nov 26, 2002
8:51:49 AM EDT
Bidding Closes: Nov 29, 2002
8:55:37 AM EDT
Viewed (by coders): 353 times
Deadline: 12/6/2002
TIME EXPIRED
Phase:
100% of work completed and accepted. Coder has been paid.
Max Accepted Bid: Bidding is closed
Project Type: Very Small Business Project: under $100 (USD)
Bidding Type: Open Auction
Categories: Database, SQL Server, MySQL, Oracle, Other DB
Enter chat room for this bid request
(0 active users at May 9, 2003 10:25:35 AM EDT)

Description:
I need a sql query that will optimise searching a 2 column table; img_id int, word_num int.
Img_id contains a number associated with an image, word_num contains values associated with a keyword which is belonging to that image.
The table surrently has over 2 million rows, note an image may have up to 500 word_nums associated with it.
I need a query that will return results for the following questions for example:

Give me all img_id&'s that have word num 44809 and 44756 or 45829 not 50076

I have some queries that I have been working on :

select distinct i.img_id, img_sku, img_cdnr,i.sorting as img_cdnr from
image i inner join (select img_id from image_key (index =idx_word_num) where
(word_num in (44809)) or
(word_num = 44756 or word_num = 45829)
group by img_id having count(*) > 1) k on i.img_id = k.img_id
and
k.img_id not in (select img_id from image_key (index =idx_word_num) where word_num in (50076))
order by i.sorting desc


select distinct img_id from image_key where img_id in (select img_id from image_key (index =idx_word_num) where word_num
in (44809,44756) group by img_id having count(*) > 1
union
select img_id from image_key (index =idx_word_num) where word_num
in (44809,45829) group by img_id having count(*) > 1)
and img_id not in (select img_id from image_key (index =idx_word_num) where word_num in (50076))

The query will have to allow unlimited “and” “or” and “not” so it could be select * where img_id is (1 and 2 and 3 and 4 and 5 and 6) or (7 or 8 or 9 or 10) but not (87,65,43,21)

I&'m looking for something that will return fast results in PostgreSQL, however ANSI SQL 92 syntax will work on postgre the only problem so I have found is that I can&'t give it an optimiser hint like I do in SQL.
I will also accept an answer that suggests another and better method of achieving the result I need, even if it means redesign of the tables.


Deliverables:
1) Complete and fully-functional working query



Platform:
POSTGRESQL or ANSI92 SQL

Must be 100% finished and received by buyer on:
Dec 6, 2002 EDT
Deadline legal notes: All times are expressed in the time zone of the site EDT (UT - 5). If the buyer omitted a time, then the deadline is 11:59:59 PM EDT on the indicated date.


Remember that contacting the other party outside of the site (by email, phone, etc.) on all business projects < $500 (before the buyer's money is escrowed) is a violation of both the software buyer and seller agreements. We monitor all site activity for such violations and can instantly expel transgressers on the spot, so we thank you in advance for your cooperation. If you notice a violation please help out the site and report it. Thanks for your help.
 
Bidding/Comments:
All monetary amounts on the site are in United States dollars.
Rent a Coder is a closed auction, so coders can only see their own bids and comments. Buyers can view every posting made on their bid requests.

See all rejected bids (and all comments)
Name   Bid Amount 
 
Date   Coder Rating  
Wave Infotech (Jinesh)
(15 ratings)
in Mumbai, Maharashtra
India
Bid id: 404,728
 
N/A Nov 26, 2002
11:43:32 AM EDT
 10
(Excellent)
   
Dear kdundon,
Will it be possible for you to send me the table structure and some sample data so that I can try it out locally at my end to suggest you the bestquery / alternative?.
Regards,
Jinesh
 
 
 
 
  See 24 private reply(ies)
to/from Wave Infotech (Jinesh).
 




Quick Search
 

 Advanced Search
Newest Open Work
Latest News

 
Credentials


 

 
Rent A Coder upholds the rigorous business practices required to be both a BBB member and Square Trade vendor.
  • All customer issues addressed within 2 days
  • Openly disclosed pricing and return policies
  • Participation in mediation at buyer request
  • Superior selling track record
This site is verified through its parent company, Exhedra Solutions, Inc.
 

Rent A Coder Top Coders.


Anuj Gakhar
Rated a 9.98 on 92 jobs 
Securenext
Rated a 9.98 on 97 jobs 
Buddies
Rated a 9.82 on 76 jobs 
Codman
Rated a 9.97 on 137 jobs 
Andrei Remenchuk
Rated a 10 on 12 jobs 
Michael Sharp
Rated a 9.98 on 168 jobs 
teleCODERS
Rated a 9.93 on 67 jobs 
RNA
Rated a 9.93 on 35 jobs 
hernest
Rated a 10 on 109 jobs 
markesh
Rated a 10 on 21 jobs 

See all top coders...

(What makes a top coder?)

Top Exam Scorers
 
Other
Rent A Coder is PayPal verified through its parent company, Exhedra Solutions, Inc.

Created in partnership with:

 


Affiliate Sites



Latest News | About Us | Kudos | Feedback/Contact    Affiliates | Advertise    Privacy | Legal

Copyright © 2001, Exhedra Solutions, Inc. All rights reserved.
By using this site you agree to its Terms and Conditions.
"Rent A Coder" (tm), "Safe Project Escrow" (tm) and "How Software Gets Done" (tm)
are trademarks of Exhedra Solutions, Inc.