Only query required fields from the WP Database.
This commit is contained in:
parent
2569e9fb5e
commit
fb49027997
|
@ -15,7 +15,7 @@ module Jekyll
|
||||||
# post in wp_posts that has post_status = 'publish'.
|
# post in wp_posts that has post_status = 'publish'.
|
||||||
# This restriction is made because 'draft' posts are not guaranteed to
|
# This restriction is made because 'draft' posts are not guaranteed to
|
||||||
# have valid dates.
|
# have valid dates.
|
||||||
QUERY = "select * from wp_posts where post_status = 'publish' and post_type = 'post'"
|
QUERY = "select post_title, post_name, post_date, post_content, post_excerpt, ID, guid from wp_posts where post_status = 'publish' and post_type = 'post'"
|
||||||
|
|
||||||
def self.process(dbname, user, pass, host = 'localhost')
|
def self.process(dbname, user, pass, host = 'localhost')
|
||||||
db = Sequel.mysql(dbname, :user => user, :password => pass, :host => host)
|
db = Sequel.mysql(dbname, :user => user, :password => pass, :host => host)
|
||||||
|
|
Loading…
Reference in New Issue