create the different logfile with different schema by coil

Hello
I want to know how to create a different log file depend on different schema
I have two patterns on the same db Server
(1) drawing kennam / * / kennam
(2) diagram koonhey / * / koonhey
in a way, I want to create a log file name different for example kennam.log / koonhey.log on these two patterns...
I always run @showbalance; to run showbalance.sql to create this report...
I hope you understand what I'm talking about (English is not my mother tongue...), anyone could help?

showbalancelog. SQL
coil c:\log.log+.
spool c:\log.log
select to_char(sysdate,'dd-mm-yyyy hh:mi:ss') from dual;
column com_name format a20;
select cus.tid, cus.com_name com_name, cus.com_balance, 
NVL((select sum(invoice_total) from invoice where com_id=cus.tid),0) sum_invoice, 
NVL((select sum(cheque_amount) from income where com_id=cus.tid),0) sum_income, 
cus.com_balance - 
NVL((select sum(invoice_total) from invoice where com_id=cus.tid),0) + 
NVL((select sum(cheque_amount) from income where com_id=cus.tid),0) total_balance
from customers cus
order by cus.tid;
spool off

Hello devotee,

You can select the user in a variable and then use that variable in your file name:

COLUMN act_user NEW_VALUE act_user NOPRINT;
SET TERMOUT OFF
SELECT USER act_user
FROM    dual;
SET TERMOUT ON
SPOOL t:\log_&act_user..log

SELECT  'My data'
FROM    dual;

SPOOL OFF

Concerning
Marcus

Tags: Database

Similar Questions

  • Unable to create the support updating with key

    Hello Dominic,.

    I have a key of Windows 8, but not 8.1 key. I upgraded to 8.1 of the store, so I'm not able to create the support updating with the key I. Should which option I now?

    Thank you & good day,

    Ajay

    Split from: this thread

    Hello Dominic,.

    Thanks for your reply, appreciate the time taken by us keep up to date on the State of the question.

    You will need a Windows 8.1 product key in order to create a refresh on your computer Windows 8.1 support. You can activate your Windows 8.1 with your product key Windows 8 operating system after upgrade, but to create refresh media, you need a product key Windows 8.1.

    I recommend you to contact our phone support, our technical support engineers can help you in the creation of a support of refreshment with a key demonstration Windows 8.1.

    http://support.Microsoft.com/contactus/?ln=en-us

    Hope this information is useful. Feel free to write us again if you have any further questions or for any further assistance, we will be happy to help you.

  • Create the virtual machine with the ISO mounted CDROM

    Community of hell!

    Working on the vmcreate.pl script to add the creation of CD-ROM with iso data store, I got stuck on the error

    ' Invalid device configuration: ' VirtualSCSIControllerOption.numSCSICdroms '.

    I'm sure I'm missing something obvious, or this option but may not understand how to deliver this.

    I created a cdrom as follows (below test I create any CDROM, no iso file to reduce the number of layers):

    my $ BPPRR m_backing_info = VirtualCdromRemotePassthroughBackingInfo->new)

    deviceName = > ' '.

    exclusive = > 0,

    );

    my $description = description->new(label = > 'CDROM', summary = > 'cdddrom');

    my $connectable = VirtualDeviceConnectInfo->new(allowGuestControl = > 1,)

    connected = > 0,

    startConnected = > 1,

    ( State = > inmates ' / ' );

    my $ BPPRR m = VirtualCdrom->new(backup = > $BPPRRm_backing_info,

    connectable = > $connectable,

    controllerKey = > 0,

    deviceInfo = > $description,

    key => 1,

    ( unitNumber = > 1 );

    VirtualDeviceConfigSpec->new(device = > $BPPRRm,

    operation = > VirtualDeviceConfigSpecOperation->new()'add'));

    Did anyone have working example to create the virtual machine with CDRom?

    Andrey

    If someone will find this useful I followed this route Re: vmreconfig.pl add the device CD/DVD fails if the virtual machine created with vmcreate.pl

    and also I found good examples of what I need to in VMUtil.pm in cmd vmsphere libraries.

    Andrey

  • How to create the new domain with lookup?

    How to create the new domain with list of choices like terrain dDocType system?

    Administration/Admin Applets tab / SCCM / information fields.
    Add field or edit a custom field if you have one.
    The name field (the name will be prefaced with the lowercase letter x behind the scenes, if ever, you write the code to call it if you name this Fruit it will xFruit for code)
    Define your values for the field, but the important thing for a menu drop-down list or list of selection will be to list the Option activate the checkbox.
    Then, you perform one of the 3 main things to put data in the list.
    1. manually fill in a list of options
    2. use a DB or DB table view to view Configuration Manager
    3. create a complex tree (read the documentation on which I him have not used)

    If this does not answer your questions, click the help button in the applet.

  • Create the form on table in the different schema

    Hi all

    in APEX I am logged in as long as user APEX_USER and the table, I'm trying to access the site with the creation on Table Wizard form belongs to the user. I have granted all privileges on a given user APEX_USER table, the wizard allows me to choose this table in the list, but when I press the next button, I get the following error message:

    You do not have access to the schema that you import. Import failed.

    Contact your administrator for the application.

    Seems to me that something similar had been already discussed here, but still no response.

    V4.1 assistants when you use a different schema

    Please, what are the rights must have my APEX_USER to be able to create forms tables belonging to someone else?

    Thank you very much

    Pavel

    Edit: I did the same thing on my laptop (APEX 4.2.6.00.03) here and it works as expected. This error I get to work with APEX 4.2.3.00.08 (of course you should not necessarily be the cause, very likely, I don't have all of the necessary privileges) :-).

    Hi Mike,.

    Thanks again for your response. If the schema was not related to my workspace, I would yet be able to choose the other schema of the selection list.

    In fact, there seems to be a bug in the link in my message original (for example it is still not fixed in version 4.2.3), but fortunately I was able to find a workaround - I created a view with the same name and the same structure as the original table, and then I was able to generate the form with the wizard , finally I gave up the display and modification of processes page manually. So the solution is I have to force the DBA APEX upgraded to the current version :-).

    Best regards

    Pavel

  • Satellite P840: How to create the secure boot with UEFI Bios recovery disk

    Hello

    I have laptop P840 that came pre-installed with Windows 8, which I've upgraded to Windows 8 Pro.
    I then updated to Windows Pro 8.1 by Windows store. Please notify:

    1. how to create a DVD repair or start for windows 8.1 pro with UEFI Bios and boot secured.

    2. I created a USB recovery using the control panel in Windows Pro 8.1. It starts OK. It will be the same as that I've created using the Toshiba Media recovery creator or will it drivers Windows Pro 8.1?

    3. check partitions with disk management, then 3 (450MO, 350 MB and GB 10.90) recovery partitions, 1 EFI system partition and 2 primary (C: programs) and D: for data. I created the recovery DVD and USB 2 disks. Can I remove the 3 recovery partitions?

    Your help will be very appreciated.

    Best regards

    Romero

    I found your previous thread on this topic:
    http://forums.computers.Toshiba-Europe.com/forums/thread.jspa?threadID=74272

    > 1. How to create a DVD repair or start for windows 8.1 pro with UEFI Bios and boot secured.
    To be able to boot from sources other than the drive HARD internal, the boot mode must be set to the CSM and secure boot must be disabled!

    > 2. I created a USB recovery using the control panel in Windows Pro 8.1. It starts OK. It will be the same as that I've created using the Toshiba Media recovery creator or will it drivers Windows Pro 8.1?

    Your laptop has been preloaded with Win 8. Right? For example, the USB flash stick memory you just use the Toshiba Recovery media creator contains the Image of Toshiba with Windows 8. Don t mix this Toshiba image with the image that can be created using Microsoft's own backup and restore function. Both are different pictures!

    > 3. Check it with disk management, then 3 (450MO, 350 MB and GB 10.90) recovery partitions, 1 EFI system partition and 2 partitions primary (C: programs) and D: for data. I created the recovery DVD and USB 2 disks. Can I remove the 3 recovery partitions?

    The last partition contains the files on HARD drive recovery. Usually this partition will be created again when you use the Toshiba Recovery disk to put the laptop back to factory settings. So in the case where you n t need this files or the partition, you can delete

  • Create the first machine with vCac 6.0.1

    Hi guys, I have a lot of confusion with vcac and vco.

    I have installed and configured the identity, vcac e device device a windows server for vcac iaas.

    I have configured the tenant in the vcac reservation... and vsphere vcenter agent after, I create a server model of win2008r2 to clone.

    I create a profile network with the ip address range and a master plan for commissioning the clone of model.

    but the problem is the clone never change the hostname, ip address and never join domain.

    I want to know if all this 'simple' work I do with only vcac or I have to use the vCO

    How can I configure machine clone with a different ip address, hostname and joined in the field by the tenant?

    Thank you

    You will need to build a specification on vCenter and attach it to the EHR Architecture on vCAC. This will customize the OS when commissioning occurs.

    Here's a screenshot for your reference. Locate the field marked in black.

  • Failed to create the Proxy service with transport JCA

    Hello everyone.
    I have some questions when trying to create the ftp with jca transport service. I followed the instructions in this tutorial:
    http://blogs.Oracle.com/MarkSmith/entry/osb_and_ftp_adapter_in_11g

    I stuck at step 4, cannot create proxy service to use JCA file I created by JDeveloper 11 g (11.1.1.5). When I specify the file of jca proxy service, an error message returned:
    <ALSB Console> <BEA-494002> <Internal error occured in OSBConsole : Transport exception occurred with the following message:
    Invalid JCA file for JCA proxy service. If you are creating a Proxy from a Business Service, please select a different transport type (for example, http). If not, JCA file must contain JCA activation spec properties.
    And here's my content created by JDeveloper jca file:
    <adapter-config name="myJCA_FTP_service" adapter="FTP Adapter" wsdlLocation="myJCA_FTP_service.wsdl" xmlns="http://platform.integration.oracle/blocks/adapter/fw/metadata">
      
      <connection-factory location="eis/ftp/MyFtpAdapter"/>
      <endpoint-interaction portType="Put_ptt" operation="Put">
        <interaction-spec className="oracle.tip.adapter.ftp.outbound.FTPInteractionSpec">
          <property name="PhysicalDirectory" value="/home/FTP-shared/upload"/>
          <property name="FileType" value="ascii"/>
          <property name="Append" value="false"/>
          <property name="FileNamingConvention" value="osb_%SEQ%"/>
          <property name="NumberMessages" value="1"/>
        </interaction-spec>
      </endpoint-interaction>
    
    </adapter-config>
    Is there someone who had attempted to use JCA adapter Ftp transport already? Please give me a suggestion.
    Any response is appreciated

    Best regards, Cuong Pham

    If you have selected the operation PUT you can only generate a business of the JCA service.

  • Is it possible to create the text block with non-uniform formatting is applied to the text?

    Hi all

    By this script

    var doc = app.documents.add(70, 20, 300, "Test", NewDocumentMode.RGB);
    var textLayer = doc.artLayers.add();
    textLayer.name = "Text";
    textLayer.kind = LayerKind.TEXT;
    
    var solidColorRef = new SolidColor();
    solidColorRef.rgb.red = 0;
    solidColorRef.rgb.green = 174;
    solidColorRef.rgb.blue = 239;
    
    var ti = textLayer.textItem;
    with (ti) {
         contents = "Blah-blah-blah!";
         kind = TextType.PARAGRAPHTEXT;
         height = new UnitValue("20 mm");
         width = new UnitValue("70 mm");
         position = [ new UnitValue("0 mm"), new UnitValue("0 mm") ];
         font = "MinionPro-Bold";
         size = new UnitValue("24 pt");
         color = solidColorRef;
         justification = Justification.CENTER;
    }
    

    So I can create a block of text with uniform like formatting

    SNAG-0011.png
    But, as far as I understand it, it is impossible to make an image and apply different sizes, colors, etc. (Please confirm or refute it).

    To achieve the result by script as follows:

    SNAG-0014.png

    The r to Browse datashows the formatting only to the beginning of this text.


    What I want to achieve is to take a block of text in the InDesign document and re-create it in psd-file. (The text must be editable)

    Y at - it another way to achieve this: by plug-ins, extensions, incantation, etc.?

    Kind regards
    Kasyan

    So that other things I noticed, it's text.jsx does not work with UnitValues. It uses the action Manager to work with textRanges. And it seems that Adobe changed the textItem units operating. Therefore, it is difficult to understand what values to use. Text.addNewTextLayer () and Text.modifyTextLayer () seem to what different values for the text of the same size.

    So below is an example updated the PS-Scripts-post on how to create a text layer with different textRanges using the current text.jsx.Note I've hard-coded sizes for that to work as I had hoped.

    function tsrDemo(doc) {
         var doc = app.documents.add(new UnitValue(70,'mm'), new UnitValue(20,'mm'), 300, "Test", NewDocumentMode.RGB);
         // we want to create a new text layer so create a new TextOptions with the contents as the argument
          var opts = new TextOptions("Blah-blah-blah!");
           // override the default settings
           opts.layerName = "Test";
           opts.kind = TextType.PARAGRAPHTEXT;
           opts.height = 800;// pixels
           opts.width = 200;
           opts.position = [ 0, 0 ];// pixels
           opts.justification = Justification.CENTER;
           opts.font = Text.findFont("Minion Pro Bold");
           opts.size = 6;// not sure what unit this needs
           opts.color = Text.toRGBColor(0, 174, 239);
    
           // create a new text layer with those options
         var layer = Text.addNewTextLayer(doc, opts);
    
           var opts = new TextOptions( layer.textItem);
           opts.contents = layer.textItem.contents;
           // now need to construct TextStyles for each range we want to set
           // for ranges we can only change the font, size, and color
           // first set a textStyle that matches the TextOptions
          var s1 = new TextStyle(undefined,undefined,undefined);
           // now set a textStyle for each different style you want
          var s2 = new TextStyle(undefined, 12, Text.toRGBColor(0, 0,0));// for some reason size values here are not the same scale as above
           // define more TextStyles as needed. here we only need one
    
          // Now create the set of ranges to apply the styles over
          var ranges = new TextStyleRanges();
           // the first range must start at 0.  In this example we want the first range unchanged
           // so we use the TextStyle that matches the TextOptions
           // this range covers the entire contents
          ranges.add(new TextStyleRange(0, opts.contents.length, s1));
           // this range covers the middle 'blah'
           ranges.add(new TextStyleRange(5, 9, s2));
            // we now add the ranges we set to the TextOptions
          opts.ranges = ranges;
    
           Text.modifyTextLayer(doc, opts, doc.activeLayer); 
    
        };
    
        tsrDemo();
    
  • How to create the default column in XML schema?

    Hi all

    I would like to define a default column Let's say Run_Date as Date data type in XML (XSD) schema definition and would fill column Run_Date SYSDATE, when XML documents are parsed to this schema.
    Let me know, how can we achieve?

    Thanks in advance.

    Also, I can not change the contents of the XML file, because it is generated by another language, but I can change the definition of XML schema, if necessary.

    Well, if you can not change the XML instance, you cannot change the schema, it conforms to the.
    You can add an optional attribute whose value by default, but we can only use a static value.

    How do you insert the file into the table?

  • If you programmatically, via an INSERT statement, then I think your best bet is to create a new table with a relational schema XMLType column and a DATE column:

    CREATE TABLE employees (
      dt_created date default sysdate not null
    , xmldoc     xmltype
    , CONSTRAINT emp_pk PRIMARY KEY (xmldoc."XMLDATA".EMP_NO)
    )
    XMLTYPE COLUMN xmldoc STORE AS OBJECT RELATIONAL
    XMLSCHEMA "EMP.xsd" ELEMENT "Emp" ;
    

    If you choose to do so, remove the XML schema and enter it again with "genTables-online false."

  • If you have inserted the file via the XDB (FTP, WebDAV, createResource) repository and relying on the table by default feature, then you may be out of luck.
    There is probably a way to tamper with the underlying structure of GOLD among a hidden column do accept a default value, but since it is not supported I won't even try.

  • How to share data in the tables ' User_ * ' with another schema

    I want to share the data in the table WHERE USER_SEGMENTS with another schema. If I create a view and grant select on the view, when the other schema queries the view data are identical to themselves querying the SYS.user_segments table directly.
    create view sys_user_segments as select * from sys.user_segments;
    grant select on sys_user_segments to A;
    My guess is that the SYS.user_segments table is a view based on the current user.

    Is there a way to share such data without creating a copy of the table?

    Oracle: 10g

    Thank you

    If the ADMINISTRATOR is concerned about B access to DBA_SEGMENTS (or by creating DBA_SEGMENTS views that belongs to a user who has access on top and then grant access to this view of B), it seems pretty crazy allow that kind of database connection.

    If you create a database link belonged to B that connects to A, B is, in substance, given any privilege that has exercises. But it is done in a very, very dark which will no doubt be neglected in the future when someone gets a check. He'll be sitting here to wait that someone (accidentally or intentionally) Decides to exploit the security hole and do something that is causing a problem (by removing all data from a table, grabbing all the sensitive data in a table, etc.). Risks of this almost certainly far, far* far * outweigh the risks of even leaving B to obtain direct access to DBA_SEGMENTS.

    Justin

  • Create the database fails with error ORA-01505: Error adding log files

    Hi all

    hope someone can help out me, I'm creating a database by using a SQL script, the content of the script is:
    create the testora database
    the user sys identified by oracle
    the user identified by oracle's system
    LogFile Group 1 ('/ u01/app/oracle/oradata/testora/redo01a.log ',' / u02/app/oracle/oradata/testora/redo01b.log') blocksize 512 re-use, 100 m in size.
    Group 2 ('/ u01/app/oracle/oradata/testora/redo02a.log ',' / u02/app/oracle/oradata/testora/redo02b.log') blocksize 512 re-use, 100 m in size.
    Group 3 ('/ u01/app/oracle/oradata/testora/redo03a.log ',' / u02/app/oracle/oradata/testora/redo03b.log') blocksize 512 re-use, 100 m in size.
    maxLogFiles 5
    maxlogmembers 5
    MAXDATAFILES 100
    US7ASCII character set
    AL16UTF16 national character set
    Local extended management
    DataFile ' / u01/app/oracle/oradata/testora/system01.dbf' re-use of 400 m size
    SYSAUX datafile ' / u01/app/oracle/oradata/testora/sysaux01.dbf' re-use of 400 m size
    default tablespace users
    DataFile ' / u02/app/oracle/oradata/testora/users01.dbf' size 500 m reuse autoextend on maxsize unlimited
    default temporary tablespace tempts1
    tempfile ' / u01/app/oracle/oradata/testora/temp01.dbf' size 20 m reuse autoextend on maxsize 4g
    Undo tablespace undotbs1
    DataFile ' / u01/app/oracle/oradata/testora/undotbs01.dbf' size 200 m reuse autoextend on maxsize unlimited
    ;

    It fails in the creation of the database with the following result:

    SQL > @/home/oracle/Oracle_Scripts/testora_db_script.sql
    create the testora database
    *
    ERROR on line 1:
    ORA-01092: ORACLE instance is complete. Disconnection forced
    ORA-01501: CREATE DATABASE failed
    ORA-01505: Error adding log files
    ORA-01184: logfile group 1 already exists
    Process ID: 3486
    ID of the session: 1 serial number: 3

    This is the documentation: http://docs.oracle.com/cd/E11882_01/server.112/e26088/statements_5004.htm#i2142335
    >
    If only the DB_RECOVERY_FILE_DEST initialization parameter is specified, Oracle database then creates a log file member to this place.

  • Create the AD: Use with a UPN defined

    I have a workflow by using the createUserWithPassword action. This creates an AD object: User fine. Unfortunately the action does not create a user AD with a UPN defined object. Instead the user is created with the UPN name as one @...

    UserWithoutUPN.jpg

    I have reproduced the default action and amended to include the userPrincipalName in the settings.

    {if (Password)}

    If (password! = confirmPassword) {}

    throw "could not create a new user: password not confirmed."

    }

    }

    try {}

    container.createUserWithPassword (accountName, password, domain name, displayName, userPrincipalName);

    }

    {} catch (ex)

    throw "could not create a new user:"+ ex;»

    }

    I have added a scriptable task until the action is running to fill the userPrincipalName and this linked to the action attribute.

    userPrincipalName = AccountName var + "@corp.local";

    System.log ("username for account creation is:" + userPrincipalName)

    Unfortunately AD accounts still get created without a UPN. Any ideas how to create users with a UPN defined. The API Explorer shows this as an option...

    userPrincipalName.jpg

    Thank you

    Don't know what you're doing wrong here, then take a look at my results:

    vRO 7.0.1

    AD plugin 2.0.7

    Active Directory 2012

    My entries:

    My TestUser1 result:

    As you can see, the unmodified library workflow creates the user properly. There is no need to specify userPrincipalName.

    In addition, the container.createUserWithPassword method doesn't have a 5th param also passing userPrincipalName as a 5th param does nothing. See the API Explorer for more information on the objects, their methods and their supported parameters:

  • Create the directory objects with the path environment variable

    I need to create a directory object and wonder if it's valid to use an environment variable in the nom_chemin?  Example:

    CREATE or REPLACE DIRECTORY XMLDIR AS ' $ORACLE_HOME/rdbms/xml ";

    I read the following in the Oracle 11.2 documentation, but it is is not clear to me if an environment variable is allowed or not.  My reason for wanting to use a variable of environment as opposed to hard coding is for when I update, I have no back reference to the old House of Oracle.

    nom_chemin

    Specify the name of the full path of the directory on the server where the operating system files are located. Single quotes are required, so that the path name is case-sensitive.

    > I see that many developers have created objects to directory with the environment variables in the path.

    Please post reproducible test

    You know & realize that the Oracle database is independent of the operating system (OS)?

    Environment variable is OS specific.

  • Cannot create the p12 certificate with existing certificate of distribution

    Hello

    I published apps before using my employers apple developer account that is simple enough forward if you follow the instructions. Asked me to create an application for distribution with the apple store using the developer account. I need to create the final application .zip and pass it to the customer who shall submit the actual application is.

    My problem is that I can't create a p12 certificate to attach to the DPS App Builder app. The customer has three certificates of distribution in their account, but had third party create them on their behalf. To my knowledge, the best way to handle this would be to revoke old certificates three distribution in their apple developer account and create a new linked to my machine that would allow me to create all the necessary certificates. It seems that 3 certificates of distribution is the limit they may have at any given time.

    My questions are:

    1. is my solution, right?

    2. If so, revoke a certificate of distribution would cause problems for one of their other applications that are published or in progress?

    The only other option that I could see was the creator of one of the certificates in distribution create a p12 certificate that I relate to the DPS App Builder app.

    Any help, advice or pointing me in the right direction would be greatly appreciated. I've never had a problem of edition following the directions, so it is a new issue for me.

    Kind regards

    C

    If you have access to your Apple dev account, you can create certificates on your machine, but if they have existing certificates in their account, could cause confusion and don't want to mess with their existing certificates.

    You advise to ask your client to create and pass the CERT, create the app with their certificates and pass back the zip for them to download

Maybe you are looking for