Re: [GTALUG] Selectively restoring WordPress posts from old SQL dump

2017-03-29 Thread ted leslie via talk
What i have done,
reload backup to a new mysql/postgres db (assuming a binary quick load
backup)
(delete what you don't want - optional)
then export db using text insert ability (not a binary blob).[can't
remember args for mysql/postgres off top of my head, but they are there]
then run it as a script based import to DB (which takes longer, but)
no copy and paste, just direct the insert script to the db.
You may have an issue if you attempt to over-write a key. (auto index key).
You may want to also state the db you are using, hey maybe its msSQL :)

-tl


On Wed, Mar 29, 2017 at 11:24 PM, William Witteman via talk  wrote:

> I have a bunch of WordPress blogs sharing a database, which seemed
> like a good idea at the time.
>
> Now I have a bunch of posts that were overwritten at *some* time in
> the past by bad data, but my backups are good.
>
> My backup testing works perfectly well for complete replacement, but I
> don't want to do that - I want to cherry-pick for one blog of several,
> and only replace posts that existed in November with the same IDs in
> today's database, but leave everything else alone.
>
> Does anyone have any thoughts?
>
> Right now I am hoping not to have a couple of terminals open and try
> to manually run UPDATEs with copy-n-paste, because that seems rather
> error-prone.
>
> Thanks!
>
> William
> ---
> Talk Mailing List
> talk@gtalug.org
> https://gtalug.org/mailman/listinfo/talk
>
---
Talk Mailing List
talk@gtalug.org
https://gtalug.org/mailman/listinfo/talk


[GTALUG] Selectively restoring WordPress posts from old SQL dump

2017-03-29 Thread William Witteman via talk
I have a bunch of WordPress blogs sharing a database, which seemed
like a good idea at the time.

Now I have a bunch of posts that were overwritten at *some* time in
the past by bad data, but my backups are good.

My backup testing works perfectly well for complete replacement, but I
don't want to do that - I want to cherry-pick for one blog of several,
and only replace posts that existed in November with the same IDs in
today's database, but leave everything else alone.

Does anyone have any thoughts?

Right now I am hoping not to have a couple of terminals open and try
to manually run UPDATEs with copy-n-paste, because that seems rather
error-prone.

Thanks!

William
---
Talk Mailing List
talk@gtalug.org
https://gtalug.org/mailman/listinfo/talk


Re: [GTALUG] testing CURL without real server

2017-03-29 Thread Lennart Sorensen via talk
On Wed, Mar 29, 2017 at 01:43:47AM -0400, ted leslie via talk wrote:
> nc -l 8080

nc -l -p 8080 works better here.  But certainly a goot idea.

> then curl to 127.0.0.1:8080

-- 
Len Sorensen
---
Talk Mailing List
talk@gtalug.org
https://gtalug.org/mailman/listinfo/talk


Re: [GTALUG] testing CURL without real server

2017-03-29 Thread Myles Braithwaite via talk
On Wed, Mar 29, 2017 at 12:45 AM, William Park via talk  wrote:
> Question for curl expert...
>
> I want to see what curl sends out, because I want to know what a proper
> HTTP request looks like.  Manpage says -v or --trace.  OK.  But, curl
> requires a real URL to connect to.
>
> How can I run curl without specifying a real server/URL?  I can't find
> any "dry-run" or "fake" options.

I use  when I need to test an HTTP client and
what it's request is.
---
Talk Mailing List
talk@gtalug.org
https://gtalug.org/mailman/listinfo/talk


Re: [GTALUG] testing CURL without real server

2017-03-29 Thread Jamon Camisso via talk
On 29/03/17 00:45, William Park via talk wrote:
> Question for curl expert...
> 
> I want to see what curl sends out, because I want to know what a proper
> HTTP request looks like.  Manpage says -v or --trace.  OK.  But, curl
> requires a real URL to connect to.

https://www.w3.org/Protocols/rfc2616/rfc2616-sec5.html describes the
range of what an HTTP 1.1 request can look like. e.g. OPTIONS, POST,
request headers for specifying content types etc.

Cheers, Jamon
---
Talk Mailing List
talk@gtalug.org
https://gtalug.org/mailman/listinfo/talk