Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Feature Requests

Development::Feature Requests Post suggestions/feature requests here.

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #7  
Old 05-29-2008, 02:32 PM
eski2
Hill Giant
 
Join Date: May 2008
Location: sydney
Posts: 177
Default

Quote:
Originally Posted by ndnet View Post
...
Code:
INSERT INTO merchantlist_tskills (itemid) (
SELECT 
	tradeskill_recipe_entries.item_id
FROM
	tradeskill_recipe,
	tradeskill_recipe_entries
WHERE
	tradeskill_recipe.id = tradeskill_recipe_entries.recipe_id AND
	tradeskill_recipe.tradeskill = TRADESKILLNUMBER AND
	tradeskill_recipe_entries.successcount = 1
);
I'm uncertain as to what are things i should change in this code quote, but i'm assuming all i have to do is swap TRADESKILLNUMBER for 60 if i want a baker merchant.
Quote:
Originally Posted by ndnet View Post
Code:
INSERT INTO merchantlist (merchantid, slot, item)
(SELECT 'MERCHANTID', slot, itemid FROM merchantlist_tskills);
This grabs the data from our temporary table, adds an extra field (the merchantid), and throws it all into the merchantlist table, creating the merchant's inventory data. In your response, this doesn't appear to have been run because there were no entries with that merchantid.

If i do this verbatim, i get the error "Incorrect integer value: 'MERCHANTID' for column 'merchantid' at row 1" so i am guessing MERCHANTID has to be picked from
Code:
SELECT * FROM merchantlist m;
and looking at the last entry, which gives "345202 0 0" , so i blindly substitute in
INSERT INTO merchantlist (merchantid, slot, item)
(SELECT 345202, slot, itemid FROM merchantlist_tskills);
and get "Duplicate entry '345202-22129' for key 2" and then i realise i really don't know SQL at all. I try incrementing and get "Duplicate entry '345203-22129' for key 2". Maybe i need to type
INSERT INTO merchantlist (345203, slot, item) ?

I really don't know what i'm doing :P
Reply With Quote
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 01:42 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3