User Functions
Don't have an account yet? Sign up as a New User
Who's Online
Guest Users: 7
|
| View previous topic :: View next topic |
| Author |
Message |
NEO fully protected

Joined: 08 Mar 2010 Posts: 14
|
Posted: Fri Sep 17, 2010 1:11 pm Post subject: Search database from CLI? Not possible? |
|
|
Hum... I'm writing a little python app so that we can take an EDL (edit decision list) and restore from tape directly from that. But when looking in the CLI manual I can't really see any way of searching the databases. Am I just blind or is it really the case that you can't search the database from CLI?
Also can't find the libchat library referred to. =/
Cheers
/Henrik Cednert |
|
| Back to top |
|
 |
itannir RAID 5

Joined: 20 Oct 2009 Posts: 16
|
Posted: Sun Sep 19, 2010 9:01 am Post subject: |
|
|
Hi Henrik,
I sent you libchat yesterday by mail.
Here's is an excerpt from the CLI manual re. your search question:
Syntax: RestoreSelection <name> findentry <plan> <expr> ?<volume>?
Description:
Fills in the restore selection object by searching the
archive entries archived with the archive <plan>.
The <expr> contains the search expression used to locate
records. The <expr> has the following generic format:
<key1> <op1> <val1> && <key2> <op2> <val2> ...
The <key> is the name of the key as passed during
archiving of the entry in "ArchiveSelection <name>
addentry" or "ArchiveSelection <name> addentry
adddirectory" methods.
The <op> is the logical operation applied to the value.
The <val> is the value associated with the key.
Following logical operations are allowed:
"==" key equals the value
"*=" key starts with value
Example: author *= marco && state == italy
The optional <volume> argument, if given, designates the
particular media where the entry has been stored (see
the "ArchiveEntry volume" command for more information).
This is mostly useful when plan which was used to archive
the entry is configured for cloning by using two media
pools.
NOTE:
Only entries that are located on "known" or "accessible"
volumes are reported. If an entry is found in the index
but is located on "unaccessible" volume (volume is disabled,
not currently mounted in some tape drive or not found in
any known media changer), it is not included in the selection.
Return values:
On success, number of entries in the selection.
On failure, the empty string.
Cheers,
Ibrahim |
|
| Back to top |
|
 |
NEO fully protected

Joined: 08 Mar 2010 Posts: 14
|
Posted: Sun Sep 19, 2010 12:00 pm Post subject: |
|
|
Hi Ibrahim! =)
I have not received that email or a notification from the firewall that it was blocked, can you resend it to neo_AT_irry_DOT_com? =)
And on to your reply. Yeah I have read that, several times, and played with it but to be honest, it doesn't feel like a search? If I interpret that correctly I have to know:
a. What archive plan it was archived with
b. Some of the custom keys, values/fields, used
c. the volume have to be in the library
I don't know if I interpret it correctly but I find the manual very confusing on this subject. So let me instead tell you what I want so you can tell me if it's possible. =)
I will parse an EDL (edit decision list) file and extract loads, several hundreds, of clip names from it any my result will be a list that might look like:
C082_C010_0427UM
C083_C010_0427G6
C083_C003_0427NP
D074_C011_0427R6
C083_C010_0427G6
D074_C011_0427R6
Those particular files in this example are files from a RED camera and in my little python application I will add the appropriate extension and process the names so they are as when they were archived to tape. Once I have my list with filenames/directory names I will send that on via CLI to archiware and i want to search the database for those particular file names, without giving any other information then the filename, just like you can in the GUI.
RestoreSelection does not sound like this? Or?
Cheers
| itannir wrote: | Hi Henrik,
I sent you libchat yesterday by mail.
Here's is an excerpt from the CLI manual re. your search question:
Syntax: RestoreSelection <name> findentry <plan> <expr> ?<volume>?
Description:
Fills in the restore selection object by searching the
archive entries archived with the archive <plan>.
The <expr> contains the search expression used to locate
records. The <expr> has the following generic format:
<key1> <op1> <val1> && <key2> <op2> <val2> ...
The <key> is the name of the key as passed during
archiving of the entry in "ArchiveSelection <name>
addentry" or "ArchiveSelection <name> addentry
adddirectory" methods.
The <op> is the logical operation applied to the value.
The <val> is the value associated with the key.
Following logical operations are allowed:
"==" key equals the value
"*=" key starts with value
Example: author *= marco && state == italy
The optional <volume> argument, if given, designates the
particular media where the entry has been stored (see
the "ArchiveEntry volume" command for more information).
This is mostly useful when plan which was used to archive
the entry is configured for cloning by using two media
pools.
NOTE:
Only entries that are located on "known" or "accessible"
volumes are reported. If an entry is found in the index
but is located on "unaccessible" volume (volume is disabled,
not currently mounted in some tape drive or not found in
any known media changer), it is not included in the selection.
Return values:
On success, number of entries in the selection.
On failure, the empty string.
Cheers,
Ibrahim |
|
|
| Back to top |
|
 |
szumlins partially protected

Joined: 22 Aug 2005 Posts: 9
|
Posted: Tue May 17, 2011 2:07 pm Post subject: |
|
|
Neo, I might be reading this wrong, but using the GUI you still have to reference a Backup Index or Archive Index (which is just a client).
Are you recovering from Backup or Archive (I would assume Archive).
I might be able to help, but need a little more info. |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|
|