optimized main query for post import
This commit is contained in:
parent
4ad23d19b7
commit
0ad1482f95
@ -946,7 +946,7 @@ class GossamerForumsImporter < ImportScripts::Base
|
|||||||
# Attachment example: highest_processed_post_id = 1359862
|
# Attachment example: highest_processed_post_id = 1359862
|
||||||
|
|
||||||
# Execute the query to get all posts ordered by post_id
|
# Execute the query to get all posts ordered by post_id
|
||||||
execute_query("SELECT * FROM gforum_Post ORDER BY post_id").each do |row|
|
execute_query("SELECT post_id, user_id_fk, forum_id_fk, post_root_id, post_subject, post_time, post_message, post_likes, post_father_id, post_replies FROM gforum_Post ORDER BY post_id").each do |row|
|
||||||
post_id = row['post_id'].to_i
|
post_id = row['post_id'].to_i
|
||||||
|
|
||||||
# Skip posts that have already been processed
|
# Skip posts that have already been processed
|
||||||
|
Loading…
Reference in New Issue
Block a user