The
The solution is quite simple. Just add to the httpd.conf before Listen 80 the line
NameVirtualHost *:80
If you use SSL virtual hosts add into httpd-ssl.conf file before Listen 443 the line
NameVirtualHost *:443
Enjoy!
| pic. 1 |
| pic. 2 |
; [/modules] ; NRPE server - A simple server that listens for incoming NRPE connection and handles them. NRPEServer = 1 [/settings/NRPE/server] allowed hosts = YOUR.NAGIOS.SERVER.ADDRESS allow arguments = true allow nasty characters = true port = 5666 timeout = 60 use ssl = 1 performance data = 1 [/settings/external scripts] allow arguments = 1 allow nasty characters = 1 timeout = 60 [/settings/external scripts/scripts] check_iis_defaultapppool=cscript.exe //nologo //T:60 scripts/Check_IISv7_AppPool_State.vbs DefaultAppPool check_iis_mypool=cscript.exe //nologo //T:60 scripts/Check_IISv7_AppPool_State.vbs "My New Pool" check_iis_longrunning=cscript.exe //nologo //T:60 scripts/check_IISv7_long_running.vbs 1000 20000NOTE: Application Pool name with spaces must be quoted as was described in the previous post!
#hide junk queue
$Self->{TicketAcl}->{'ACL-hide-junk-queue'} = {
# match properties
Properties => {
# all tickets
Ticket => {
},
#only on AgentTicketZoom page
Frontend => {
Action => [
'AgentTicketZoom',
],
},
},
PossibleNot => {
# shouldn't be moved into
Ticket => {
Queue => ['Junk', 'SPAM'],
},
},
};
Enjoy!
The resulting SQL file contains single insert per line and GO after each line. The file can be loaded into MSSQL compact edition (CE) with utility SqlCeCmd40#!/usr/bin/perl # MySQL dump was created as # >mysqldump -u USER -p --no-create-info --extended-insert DB_NAME > mysql_dump.sql while(<>){ if(/^(INSERT INTO .*? VALUES)(.*)$/i){ my $insert_into_table = $1; my $values = $2; $insert_into_table =~ s/`//g; (my $table_name = $insert_into_table) =~ m/INSERT INTO (.*?) VALUES/; my @arr_values = $values =~ m{ \( # opening ( ( # Start capture (?: # non-capturing group [^()']+ # ignore inner brackets | '[^']*' # skip all between single quotes )* # and repeat ) \) # final ) }gx ; foreach(@arr_values){ print "$insert_into_table ($_);\n"; print "GO\n"; } } } 1;
ISBN 978-0735624009[/caption]
Get comprehensive guidance for using the Microsoft Language Integrated Query (LINQ) Project with in-depth insights from two experienced developers. Data-rich applications can be difficult to create because of the tremendous differences between query languages used to access data and programming languages commonly used to write applications. This practical guide covers the intricacies of LINQ, a set of extensions to the Visual C# and Visual Basic programming languages. Instead of traversing different language syntaxes required for accessing data from relational and hierarchical data sources, developers will learn how to write queries natively in Visual C# or Visual Basic helping reduce complexity and boost productivity. Written by two experienced developers with strong ties to developer teams at Microsoft, this book describes the LINQ architecture and classes, details the new language features in both C# and Visual Basic, and provides code samples in both languages.
SELECT distinct DATE_FORMAT(create_time, 'mkdir %Y\\%m\\%d') a FROM ticket
SELECT CONCAT(DATE_FORMAT(a.create_time, 'move %Y\\%m\\%d\\'),convert(a.id,char(20)), ' C:\\path_to_new_OTRS\\var\\article\\',DATE_FORMAT(a.create_time, '%Y\\%m\\%d\\')) a
FROM article a JOIN ticket t ON t.id=a.ticket_id
WHERE t.queue_id in (1,3,5,10);
using System;Custom aggregationusing System.Collections.Generic;using Microsoft.VisualStudio.TestTools.UnitTesting;using CrossTab;using System.Data;namespace UnitTest{[TestClass]public class UnitTest1{[TestMethod]public void TestMethod1(){object DBNULL = DBNull.Value;DataTable src = new DataTable();DataTable dst = null;src.Columns.Add("City", typeof(string));src.Columns.Add("Product", typeof(string));src.Columns.Add("Value", typeof(double));src.Rows.Add("City A", "Product 1", 1.2);src.Rows.Add("City C", "Product 2", 0.3);src.Rows.Add("City A", "Product 1", 1.0);src.Rows.Add("City B", "Product 3", 2.2);src.Rows.Add("City B", "Product 1", 1.5);src.Rows.Add("City A", "Product 2", 0.8);src.Rows.Add("City A", "Product 4", 1.1);PivotTable test = new PivotTable(DemoAverageCalc.Average);dst = test.Pivot(src, "Product", "City", "Value");CollectionAssert.AreEqual(new object[] { "City A", 1.1, 0.8, DBNULL, 1.1 }, dst.Rows[0].ItemArray);CollectionAssert.AreEqual(new object[] { "City B", 1.5, DBNULL, 2.2, DBNULL }, dst.Rows[1].ItemArray);CollectionAssert.AreEqual(new object[] { "City C", DBNULL, 0.3, DBNULL, DBNULL }, dst.Rows[2].ItemArray);}}}
using System;using System.Collections;using System.Text;namespace UnitTest{public class DemoAverageCalc{// my inner type is doublepublic static object Sum(ArrayList set){double ret = 0.0;foreach (object t in set){if(t is double)ret = ret + (double)t;}return ret;}public static object Average(ArrayList set){return (double)Sum(set) / (double)set.Count;}}}
FixIt says that you will find single screw under CE label. It isn't always true.