I answered my own question, this works for joining a table on itself and doing an 
update query:

update 
        discussion_categories discussion_categories1, discussion_categories
        set 
                discussion_categories1.parent_1 = discussion_categories.category_id
where 
        discussion_categories1.`parent_1_text` = discussion_categories.name



> -----Original Message-----
> From: Jonathan Patton 
> Sent: Wednesday, July 23, 2003 8:39 AM
> To: [EMAIL PROTECTED]
> Subject: update query using inner join on same table
> 
> 
> Hi, 
> 
> I have a query that runs in Microsoft Access against my mysql 
> database just fine. It is: 
> 
>  
> UPDATE discussion_categories AS discussion_categories_1 
> INNER JOIN discussion_categories ON 
> discussion_categories_1.parent_1_text = discussion_categories.name 
> SET discussion_categories_1.parent_1 = 
> [discussion_categories].[category_id];
> 
> 
> I tried to write this in mysql but couldn't figure it out. Is 
> it possible to join a table on itself in mysql?
> 
> 
> -- 
> MySQL General Mailing List
> For list archives: http://lists.mysql.com/mysql
> To unsubscribe:    
> http://lists.mysql.com/[EMAIL PROTECTED]
> 
> 

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to