Time |
Nick |
Message |
07:58 |
|
BDorsey joined #evergreen |
08:00 |
|
cbrown-isl joined #evergreen |
08:40 |
|
kworstell-isl joined #evergreen |
08:41 |
|
mmorgan joined #evergreen |
08:50 |
|
collum joined #evergreen |
09:05 |
|
Dyrcona joined #evergreen |
10:08 |
|
rlefaive joined #evergreen |
10:13 |
rlefaive |
Hello all, just wanted a quick poll of whether there are good tools available for round-tripping marc records. I have a table of record IDs and URLs that i want to replace with new URLs. I can get the records (either with Marc Import/Export, or with Supercat), transform them (with python), but I'm hoping there's a programmatic way (ie. not Marc Import/Export) to upload them? I'm aware of pingest.pl but that seems m |
10:13 |
rlefaive |
ore like it indexes the records. I explored marc2bre.pl but it seems to make new records and not edit existing ones (unless i read it wrong; I'm not proficient at Perl). Is there a script that takes a marc or marc xml file and overwrites existing records as identified in 901$c? |
10:15 |
|
cbrown-isl joined #evergreen |
10:16 |
|
rlefaive joined #evergreen |
10:29 |
|
rlefaive joined #evergreen |
10:35 |
|
smayo joined #evergreen |
10:41 |
Dyrcona |
rlefaive: I've usually written something bespoke for that. You could set up marc_stream_importer.pl and through the modified records into a queue. |
10:41 |
rlefaive |
thanks Dyrcona |
10:41 |
Dyrcona |
s/though/throw/ #English is 3 languages in a trenchcoat. |
10:42 |
Dyrcona |
Bmagic has an import tool. |
10:43 |
Dyrcona |
Github is asking me to sign in, so I can look it up later. The github user is mcoia or something like that. |
10:44 |
* Dyrcona |
poofs away for a bit. |
11:26 |
Dyrcona |
rlefaive: There's also a bug Lp 1947898 and a branch for BibMagic. |
11:26 |
pinesol |
Launchpad bug 1947898 in Evergreen "BibMagic - Enhanced MARC importer script bib_magic_importer.pl" [Wishlist,Confirmed] https://launchpad.net/bugs/1947898 |
11:30 |
rlefaive |
Aha, i found how to navigate the git repo to find the code! Thank you Dyrcona |
11:32 |
|
Christineb joined #evergreen |
12:00 |
Dyrcona |
rlefaive: You're welcome. After taking a break for lunch, I finally got signed in to Github, but I think the branch proposed for Evergreen might suit your needs better. |
12:03 |
|
jihpringle joined #evergreen |
12:04 |
|
cbrown-isl joined #evergreen |
13:22 |
JBoyer |
rlefaive, there's also the marc_stream_importer which comes with Evergreen and uses some of the same backend as the UI, but can handle larger imports more reliably. |
13:22 |
JBoyer |
(It also does the OCLC Connexion "export to ILS" thing for libraries that use that) |
13:23 |
rlefaive |
🙌 thanks JBoyer. Ooh i wish we could use that. |
13:24 |
JBoyer |
If the problem is on the Eg side you know who to call. :) |
13:44 |
Dyrcona |
Once you set it up, the marc_stream_importer is pretty simple to use. You can use netcat (nc) to "throw" a file of records at it. |
14:25 |
csharp_ |
@who you gonna call? |
14:25 |
pinesol |
jweston_ me gonna call. |
14:25 |
csharp_ |
pinesol: wrong |
14:25 |
pinesol |
csharp_: Your computer account is overdrawn. Please reauthorize. |
15:18 |
Dyrcona |
hm... I used to have a little program that could run json queries from a file. I haven't used it in years. I wonder where I put it? |
15:19 |
sleary |
I am seriously considering making a folder called "a safe place" for all those little utility files. "I put that in a safe place, where was... oh, right." |
15:19 |
Dyrcona |
Here it is: https://github.com/Dyrcona/evergreen_utilities/blob/master/perl/json_query.pl |
15:19 |
sleary |
A friend suggested doing this with a box for small items that you stash around the house. |
15:20 |
Dyrcona |
I have several safe places for the utilities, alas. |
15:22 |
mmorgan |
That's always a problem: multiple safe places :) |
15:42 |
Dyrcona |
is there a way to dump the sql generated from a cstore json query? |
15:44 |
Rogan |
rlefaive if you're just talking about bulk importing marc I usually just create a staging schema/table and push them in with psql or a bespoke perl script and after making sure I have them how I like insert them from there |
15:45 |
Rogan |
sleary I have a tiny git repo called r_scripts that is nothing but small scripts I may want to use in places |
15:48 |
Dyrcona |
Error: expected function name, found JSON_NUMBER |
15:49 |
Dyrcona |
All see error log isn't useful, 'cause Postgres isn't logging anything for this query and neither is cstore stderr file. |
15:53 |
Dyrcona |
"home_ou": {"-not":[ 4, 79, 152, 200 ]}, |
15:53 |
Dyrcona |
That causes my problem.... |
15:57 |
Dyrcona |
"home_ou": {"not in": [ 4, 79, 152, 200 ]}, # Works. |
15:57 |
Dyrcona |
The documentation suggests that the former should work, too. |
15:59 |
Dyrcona |
"For a NOT IN list, you can use the latter format, using the "not in" operator instead of "in". Alternatively, you can use either format together with the "-not" operator." Lies and propaganda! |
16:00 |
Dyrcona |
"Walk it down. Tallk it down." |
16:05 |
Dyrcona |
Ah ha! This works: "-not": {"home_ou": [ 4, 79, 152, 200 ]}, |
16:07 |
Dyrcona |
Have I really gone this long misunderstanding that, or was it just a momentary lapse? |
16:08 |
Dyrcona |
I swear I also had a program to dump the SQL that's generated from JSON.... |
16:52 |
Dyrcona |
ugh.... timed events give different results depending on the time that one runs them, and expire_dates are not all at the same hour.... |
16:53 |
Rogan |
Quick note before I disappear for the weekend. Outreach is glad to share that all of the 2024 conference videos are now up on youtube https://www.youtube.com/watch?v=1CH8N2K_prQ&list=PLsktT5b82paVQ5JMpJG8hEuqxbX5wsnL2 |
16:53 |
Dyrcona |
Rogan++ |
16:56 |
* Dyrcona |
runs 'update actor.usr set expire_date = expire_date::date;' in the test database and decides to call it a week. |
17:01 |
|
rlefaive joined #evergreen |
17:28 |
|
mmorgan left #evergreen |
17:37 |
|
rlefaive joined #evergreen |
17:45 |
|
rlefaive joined #evergreen |
18:03 |
|
rlefaive joined #evergreen |
18:38 |
|
rlefaive joined #evergreen |
19:14 |
|
rlefaive joined #evergreen |
19:49 |
|
rlefaive joined #evergreen |
19:56 |
|
rlefaive joined #evergreen |
20:15 |
|
rlefaive joined #evergreen |
20:27 |
|
rlefaive joined #evergreen |
20:45 |
|
rlefaive joined #evergreen |
21:03 |
|
rlefaive joined #evergreen |
21:39 |
|
rlefaive joined #evergreen |
22:15 |
|
rlefaive joined #evergreen |
22:31 |
|
rlefaive joined #evergreen |
22:50 |
|
rlefaive joined #evergreen |
22:55 |
|
rlefaive joined #evergreen |
23:14 |
|
rlefaive joined #evergreen |
23:47 |
|
rlefaive joined #evergreen |