[rt-users] Problem creating Tickets from the commandline

Scott A. McIntyre scott at xs4all.net
Wed Jun 18 11:42:18 EDT 2003


--On Wednesday, June 18, 2003 15:57 +0200 Joerg Herbert 
<joerg at die-herberts.de> wrote:

> Hi, I am using RT 2.0.14 on Debian.
>
> I want to create an Ticket via the commandline. If I do
>
> ./rt --create --subject="test commandline8" --queue=19
> --requestors=j.herbert at pelion12.de --noedit, the ticket gets created
> fine.
>
> What information do I need for the --keyword Parameter? My trials so far
> didn't create a Ticket with any chosen Keyword set.

--keywords[+|-]<keyword_select>/<keyword>

An example works best.  Remember you must first go to the 
Configuration/Keywords area to define your keyword values.  The best option 
is to define them with a hierarchy that is easy to distinguish per queue, 
such as /queues/nameofqueue and /queues/nameofqueue2 and so on.

For example:

/queues/foo
/queues/foo/red
/queues/foo/blue
/queues/bar
/queues/bar/red
/queues/bar/blue

You would then go to Configuration -> Queues -> foo -> Keyword Selections 
and *apply* those values to a named selection, such as "colour".  You'd see 
in the interface something like:

[     ] : (Single/Multiple) children of (entire keyword hierarchy)

Now, fill in "colour" for the value in the box, then select "Single" from 
the first popup and then "/queues/foo" from the second.

Now you've coupled the globally defined keyword hierarchy with a named 
"selection" for that queue.

You may know all this, but without doing this part the command line will 
never work.  You may NOW assign the keywords to a ticket by doing:


./rt --create --subject="test" --queue=19 
--requestors=j.herbert at pelion12.de --noedit --keywords+colour/red

I don't think you need an "=" after the word keywords, but you do need the 
+ to say "add" or the "-" to remove...

Hope that helps, just say if I'm still not clear!

With kind regards,

Scott







More information about the rt-users mailing list